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

NO-ISSUE: Add NOTICE Copyright year check #6181

Closed
wants to merge 2 commits into from

Conversation

jomarko
Copy link
Contributor

@jomarko jomarko commented Dec 4, 2024

Should prevent us from tickets apache/incubator-kie-issues#1618 in the future.

Thank you for submitting this pull request

NOTE!: Double-check the target branch for this PR.
The default is main so it will target Drools 8 / Kogito.

Ports If a forward-port or a backport is needed, paste the forward port PR here

Issue: (please edit the GitHub Issues link if it exists)

referenced Pull Requests: (please edit the URLs of referenced pullrequests if they exist)

  • paste the link(s) from GitHub here
  • link 2
  • link 3 etc.
How to replicate CI configuration locally?

Build Chain tool does "simple" maven build(s), the builds are just Maven commands, but because the repositories relates and depends on each other and any change in API or class method could affect several of those repositories there is a need to use build-chain tool to handle cross repository builds and be sure that we always use latest version of the code for each repository.

build-chain tool is a build tool which can be used on command line locally or in Github Actions workflow(s), in case you need to change multiple repositories and send multiple dependent pull requests related with a change you can easily reproduce the same build by executing it on Github hosted environment or locally in your development environment. See local execution details to get more information about it.

How to retest this PR or trigger a specific build:
  • for pull request and downstream checks

    • Push a new commit to the PR. An empty commit would be enough.
  • for a full downstream build

    • for github actions job: add the label run_fdb
  • for Jenkins PR check only


- name: Check NOTICE Copyright year
run: |
(grep "Copyright $(date +%Y) The Apache Software Foundation" NOTICE && echo "NOTICE Copyright year is up to date") || (echo "NOTICE Copyright year is outdated" && exit 1)
Copy link
Contributor

Choose a reason for hiding this comment

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

Thank you for the PR.

Suggested change
(grep "Copyright $(date +%Y) The Apache Software Foundation" NOTICE && echo "NOTICE Copyright year is up to date") || (echo "NOTICE Copyright year is outdated" && exit 1)
(grep "Copyright 2023-$(date +%Y) The Apache Software Foundation" NOTICE && echo "NOTICE Copyright year is up to date") || (echo "NOTICE Copyright year is outdated" && exit 1)

Based on the PJ Fanning's suggestion ( apache/incubator-kie-issues#1618 (comment) ), I have updated the year with range 2023-2024 ( apache/incubator-kie-kogito-runtimes#3806 )

So, the grep would be like this. Thanks!

@jomarko jomarko marked this pull request as draft December 5, 2024 07:36
@jomarko
Copy link
Contributor Author

jomarko commented Dec 6, 2024

We will not implement this.

@jomarko jomarko closed this Dec 6, 2024
@jomarko jomarko deleted the notice-year branch December 6, 2024 14:55
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