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

Do not reorder existing FileCopyrightText lines #1109

Open
scy opened this issue Nov 27, 2024 · 0 comments
Open

Do not reorder existing FileCopyrightText lines #1109

scy opened this issue Nov 27, 2024 · 0 comments

Comments

@scy
Copy link

scy commented Nov 27, 2024

Currently, reuse annotate seems to reorder existing SPDX-FileCopyrightText lines by year, followed by copyright holder.

However, I would argue that it should instead only order by year, and leave existing lines alone. When adding a new one, it should be placed at the right spot chronologically, but if there are already other lines with the same year, the new one should simply be added below them.

I have two reasons for suggesting this:

  1. The file might have one or more "main" and one or more "secondary" copyright holders. For example, Bob Builder is the lead developer for the file, but Alice Avocado has worked on significant parts as well and is a copyright holder, not just a contributor. reuse would always list Alice first, which might feel wrong to Alice, Bob, or both.
  2. Adding a single contributor should be a single-line change, not potentially lead to multiple lines of diff output because reuse reordered the existing tags.

To fix this, I propose to change reuse annotate's default behavior as described above. Additionally, we could introduce a --alphabetical flag that, as before, sorts contributors alphabetically within the same year.

I'm a Python developer, I could try to create a pull request for this if you're interested, but I'd like to hear your opinions first.

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

No branches or pull requests

1 participant