Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: auto cut the overflow lines and keep only the first 1500 lines (30 pages) and the last 1500 lines (last 30 pages) as per the regulation #4

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Jeff-Tian
Copy link
Contributor

根据《中国著作权法》要求,如果代码超过3000行,word里保留前30页和后30页,每页50行。

这个改动自动完成这件事。

…(30 pages) and the last 1500 lines (last 30 pages) as per the regulation
@luxel
Copy link
Owner

luxel commented May 16, 2019

当有的一行代码在输出到word之后,实际可能会排版成2~3行,所以造成我们输出3000行代码后,实际的word文件排版会超过60页。请问这种情况在当前commit是否能支持?

@Jeff-Tian
Copy link
Contributor Author

Jeff-Tian commented May 16, 2019

通过多次试验,将每一行最大长度限制在 60 字符,可以做到。

这个 commit 有一个改动就是限制了每行截取的字符数。
image

我在自己的几个项目中使用过,的确正好60页。

@luxel
Copy link
Owner

luxel commented May 29, 2019

好的,这个功能可以做成一个可选项不?

@Jeff-Tian
Copy link
Contributor Author

Jeff-Tian commented May 30, 2019 via email

@Jeff-Tian
Copy link
Contributor Author

更新了 README,对此进行说明:

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants