Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
| zh:submitting-patches [2020/03/02 10:48] – [4. 更改内容格式检查] superice | zh:submitting-patches [2020/03/08 15:52] – [10. 签署工作] superice | ||
|---|---|---|---|
| Line 163: | Line 163: | ||
| 检查您的补丁程序是否存在“基本样式”冲突。 否则,只会浪费审阅者的时间,并且会拒绝您的补丁,甚至可能不会被阅读。 | 检查您的补丁程序是否存在“基本样式”冲突。 否则,只会浪费审阅者的时间,并且会拒绝您的补丁,甚至可能不会被阅读。 | ||
| ==== 5. 选择邮件目的地 ===== | ==== 5. 选择邮件目的地 ===== | ||
| - | Look in the Makefile | + | 请查看Makefile,是否存在MAINTAINER宏。 如果存在,则请给该人发送电子邮件。 除非您有理由不这样做,否则请始终CC openwrt-devel < |
| ==== 6. 不要使用MIME类型邮件,不要使用超连接方式,不要压缩补丁,不要使用附件方式,只使用纯文本 ===== | ==== 6. 不要使用MIME类型邮件,不要使用超连接方式,不要压缩补丁,不要使用附件方式,只使用纯文本 ===== | ||
| - | OpenWrt developers need to be able to read and comment on the changes you are submitting. It is important for an OpenWrt developer to be able to " | ||
| - | For this reason, all patches should be submitting email " | + | OpenWrt开发人员需要能够阅读和评论您提交的更改。 对于OpenWrt开发人员而言,使用标准的电子邮件工具“引用”您的更改非常重要,这样他们就可以对代码的特定部分进行注释。 |
| - | Do not attach the patch as a MIME attachment, compressed or not. Many popular email applications will not always transmit a MIME attachment as plain text, making it impossible to comment on your code. | + | 因此,所有补丁都应“内联”提交电子邮件。 警告:如果您选择剪切粘贴,请小心编辑器的自动换行会损坏您的补丁程序。 |
| - | Exception: If your mailer is mangling patches then someone may ask you to re-send them using MIME. | + | 不要将补丁附加为MIME附件,或者压缩。许多流行的电子邮件应用程序并不总是将MIME附件作为纯文本发送,使得无法对代码进行注释。 |
| + | |||
| + | 例外:如果您的邮件发送者正在处理补丁程序,则有人可能会要求你使用MIME重新发送补丁程序。 | ||
| + | |||
| + | Mozilla雷鸟要求您更改电子邮件默认值以发送纯文本电子邮件。[[http:// | ||
| - | Mozilla Thunderbird requires that you change email defaults to send plain text email. | ||
| - | read [[http:// | ||
| - | :!: disable flowed text | ||
| ==== 7. 邮件大小 ===== | ==== 7. 邮件大小 ===== | ||
| - | Large changes are not appropriate for mailing lists, and some maintainers. If your patch, uncompressed, | ||
| + | 较大的更改不适用于邮件列表和某些维护者。 如果未压缩的补丁程序大小超过300 kB,则最好将补丁程序存储在可访问Internet的服务器上,并提供指向补丁程序的URL (链接) | ||
| ==== 8. 不要灰心,重新提交 ===== | ==== 8. 不要灰心,重新提交 ===== | ||
| - | After you have submitted your change, be patient and wait. If developers like your change and apply it, it will appear as new revision in the source code management system. | ||
| - | However, if your change doesn' | + | 提交更改后,请耐心等待。 如果开发人员喜欢你的更改并应用它,它将在源代码管理系统中显示为新修订。 |
| - | Sometimes, developers may " | + | 但是,如果你的更改未出现在源代码管理系统中,则可能有多种原因。 缩小这些原因,纠正错误,然后提交更新的更改是你的工作。 |
| - | * Your patch did not apply cleanly to the latest OpenWrt revision. | + | |
| - | * Your patch was not sufficiently discussed on openwrt-devel. | + | |
| - | * A style issue. | + | |
| - | * An email formatting issue (re-read this section). | + | |
| - | * A technical problem with your change. | + | |
| - | * They get tons of email, and yours got lost in the shuffle. | + | |
| - | * You are being annoying. | + | |
| - | When in doubt, solicit comments on openwrt-devel | + | 有时,开发人员可能会“丢弃”你的补丁,而有或没有评论。 这就是系统的本质。 如果你的补丁程序被删除,则可能是由于: |
| + | |||
| + | * 你的补丁不适用于最新的OpenWrt版本。 | ||
| + | * 你的补丁在openwrt-devel上没有得到充分讨论。 | ||
| + | * 样式问题。 | ||
| + | * 电子邮件格式问题(请重新阅读本节)。 | ||
| + | * 你的更改存在技术问题。 | ||
| + | * 他们收到大量电子邮件,而你的邮件迷失了。 | ||
| + | * 你真烦人。 | ||
| + | |||
| + | |||
| + | 如有疑问,请在openwrt-devel邮件列表上征求意见。 | ||
| ==== 9. 在邮件主题中包含PTACH提示 ===== | ==== 9. 在邮件主题中包含PTACH提示 ===== | ||
| - | Due to high email traffic to openwrt-devel, it is common convention to prefix your subject line with [PATCH]. This lets OpenWrt | + | |
| + | 由于openwrt-devel的电子邮件流量很高,因此通常会在主题行前加上[PATCH]作为前缀。 这样,OpenWrt开发人员可以更轻松地将补丁与其他电子邮件讨论区分开来,并且还将自动进入补丁工作。 | ||
| ==== 10. 签署工作 ===== | ==== 10. 签署工作 ===== | ||
| - | To provide tracking of who did what, we use a " | ||
| - | The sign-off is a simple line at the end of the explanation for the patch, which certifies that you wrote it or otherwise have the right to pass it on as an open-source patch. The rules are pretty simple: if you can certify the below: | + | 为了跟踪谁做了什么,我们对正在通过电子邮件发送的补丁程序使用“签署”程序。 |
| + | |||
| + | 补丁说明末尾的签名很简单,它证明您写了它,或者有权将它作为开放源代码补丁进行传递。 规则非常简单:如果您可以证明以下内容: | ||
| < | < | ||
| Line 234: | Line 238: | ||
| </ | </ | ||
| - | then you just add a line saying | + | 然后你只需加上一句话 |
| <code bash> | <code bash> | ||
| Line 240: | Line 244: | ||
| </ | </ | ||
| - | using your real name (no pseudonyms or anonymous contributions.) | + | 使用您的真实姓名(没有化名或匿名。) |
| - | If you are a package or target maintainer, sometimes you need to slightly modify patches you receive in order to merge them, because the code is not exactly the same in your tree and the submitters' | + | 如果你是一个包或目标维护者,有时你需要稍微修改你接收到的补丁以便合并它们,因为代码在你的树和提交者中不是完全相同的。如果你严格遵守规则,你应该向提交人请求重新授权,但这完全是浪费时间和精力。规则(B)允许您调整代码,但是更改提交人的代码并使他支持您的bug是非常不礼貌的。为了解决这个问题,建议您在最后一个签名的头和您的头之间添加一行,说明您的更改的性质。虽然没有什么强制性的,这似乎是准备描述与您的邮件和/或名称,所有包围在方括号中,是显而易见的,足以使你清楚,你负责的最后一分钟的变化。例子: |
| <code bash> | <code bash> | ||
| Line 250: | Line 254: | ||
| </ | </ | ||
| - | This practice is particularly helpful if you maintain a stable branch and want at the same time to credit the author, track changes, merge the fix, and protect the submitter from complaints. Note that under no circumstances can you change the author' | + | 如果你保持一个稳定的分支,并希望同时信任作者,跟踪更改,合并修复,并保护提交者不受投诉,这种做法尤其有用。请注意,在任何情况下,您都不能更改作者的身份(从报头),因为它是在变更日志中出现的身份。 |
| - | Special note to back-porters: | + | 向后移植者的特别注意:在提交消息的顶部(仅在主题行之后)插入补丁来源的指示,以方便跟踪,这似乎是一种常见且有用的做法。 例如: |
| <code bash> | <code bash> | ||
| Line 260: | Line 264: | ||
| </ | </ | ||
| - | Whatever the format, this information provides valuable help to people tracking your trees, and to people trying to trouble-shoot bugs in your tree. | + | 无论采用哪种格式,此信息都可以为跟踪您的树的人们以及试图对树中的错误进行故障排除的人们提供宝贵的帮助。 |
| - | For the more convenient developers, | + | 对于更方便的开发人员,git可以自动添加签名: |
| <code bash> | <code bash> | ||