Skip to content

Conversation

@Parship12
Copy link

What this PR does:
Fixed the update-copyright.sh to work correctly:

  • Removing -Z from grep (using newline-separated output)
  • Adding cross-platform for sed -i (mac vs Linux)
  • Used the script and update the copyright year to 2026

Why we need it: The update-copyright.sh script was failing on linux with errors like "sed: can't read". The script grep -rlZ which causing all filenames to concatenate into one string. Also, the script used macOS sed -i '' which is not working on linux.

Does this PR introduce a user-facing change?:

  • How are users affected by this change: NA
  • Is this breaking change: NO
  • How to migrate (if breaking change): NA

Happy New Year 🎉

Signed-off-by: Parship Chowdhury <parshipchowdhury@gmail.com>
@Parship12 Parship12 requested a review from a team as a code owner January 22, 2026 04:17
@Parship12 Parship12 changed the title fix: update-copyright.sh script and update copyright year to 2026 fix: update-copyright script and update copyright year to 2026 Jan 22, 2026
Copy link
Contributor

@eeshaanSA eeshaanSA left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Parship12 Thanks for this. Two things:

  1. Please always open an issue first. It is better to discuss the ideas, and then start working on it.

  2. The script should be separately updated in one PR. This PR changes 300 files, and is difficult to review.

@Parship12
Copy link
Author

Parship12 commented Jan 22, 2026

@eeshaanSA Yeah sorry for that, actually I have done 2 things in the PR:

  1. Update the script file update-copyright.sh -> This was my main aim
  2. Ran the script: And after running the script all the files are the just updated by 2025 -> 2026.

Okay, I will create a different PR for the changes done in the script.

@Ayushmore1214
Copy link
Contributor

@eeshaanSA @Parship12 quick question , doesn't the copyright year usually represent the creation year?

@Parship12
Copy link
Author

@eeshaanSA @Parship12 quick question , doesn't the copyright year usually represent the creation year?

I thought the same, but then I found this PR: #4745

@eeshaanSA
Copy link
Contributor

@eeshaanSA @Parship12 quick question , doesn't the copyright year usually represent the creation year?

New code added in 2025 and 2026 has to reflect the changes. That is why, it is recommended, to have the current year, or the range, for example 2021-2026.

@eeshaanSA
Copy link
Contributor

@eeshaanSA @Parship12 quick question , doesn't the copyright year usually represent the creation year?

I thought the same, but then I found this PR: #4745

So, the motive of this PR is that the .hack/update-copyright.sh file fails?

@Parship12
Copy link
Author

Why we need it: The update-copyright.sh script was failing on linux with errors like "sed: can't read". The script grep -rlZ which causing all filenames to concatenate into one string. Also, the script used macOS sed -i '' which is not working on linux.

Yes, it was failing on Linux and also the file names were concatenate.

@eeshaanSA
Copy link
Contributor

Understood, thanks!

Why we need it: The update-copyright.sh script was failing on linux with errors like "sed: can't read". The script grep -rlZ which causing all filenames to concatenate into one string. Also, the script used macOS sed -i '' which is not working on linux.

Yes, it was failing on Linux and also the file names were concatenate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants