Skip to content

Add license PR checks + how to run it locally #1235

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

Merged
merged 4 commits into from
Feb 25, 2020

Conversation

0xc0170
Copy link
Contributor

@0xc0170 0xc0170 commented Feb 18, 2020

This depends on ARMmbed/mbed-os#12437
Once it is merged, this can go in (no release dependency, will be running on master for every PR)

I added a section to our license guide - how to run the license check

@ARMmbed/mbed-os-maintainers Please review

@@ -103,6 +103,22 @@ If you decide to use a different license for your work, follow the same pattern:

- If more than one license applies to the source file, use an SPDX license expression (see [SPDX Specification, Appendix IV](https://spdx.org/spdx-specification-21-web-version#h.jxpfx0ykyb60)), to reflect the presence of multiple licenses in your *LICENSE.md* file and in each source file.

## License check in pull requests

We use scancode-toolkit to enforce the license in binaries and libraries. Please see "Continuous integration (CI) testing" section for more information.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I can move Please see "Continuous integration (CI) testing" section for more information. to the end of this section, shall I?

Copy link
Contributor

Choose a reason for hiding this comment

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

I'm agnostic on this one.

@0xc0170
Copy link
Contributor Author

0xc0170 commented Feb 24, 2020

The pull request adding license check using scancode was merged to master. This can progress (as the checks are being active from today for all PRs).

@@ -24,7 +24,7 @@ Travis configuration is located in the [.travis.yml](https://github.com/ARMmbed/
- Features/netsocket.
- **travis-ci/events** - Checks that Mbed OS compiles and run events tests.
- **travis-ci/gitattributestest** - Checks there are no changes after clone. This checks that `.gitattributes` is used correctly.
- **travis-ci/licence_check** - Checks there is no GPL license text in the code.
- **travis-ci/licence_check** - Checks there is only permissive license in files, including SPDX identifier.
Copy link
Contributor

Choose a reason for hiding this comment

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

only a permissive license in the files,

@@ -103,6 +103,22 @@ If you decide to use a different license for your work, follow the same pattern:

- If more than one license applies to the source file, use an SPDX license expression (see [SPDX Specification, Appendix IV](https://spdx.org/spdx-specification-21-web-version#h.jxpfx0ykyb60)), to reflect the presence of multiple licenses in your *LICENSE.md* file and in each source file.

## License check in pull requests

We use scancode-toolkit to enforce the license in binaries and libraries. Please see "Continuous integration (CI) testing" section for more information.
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm agnostic on this one.


We use scancode-toolkit to enforce the license in binaries and libraries. Please see "Continuous integration (CI) testing" section for more information.

To scan the files in SCANCODE folder, please use:
Copy link
Contributor

Choose a reason for hiding this comment

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

in the

@0xc0170
Copy link
Contributor Author

0xc0170 commented Feb 24, 2020

Updated, fixed the above requested changes

@@ -24,7 +24,7 @@ Travis configuration is located in the [.travis.yml](https://github.com/ARMmbed/
- Features/netsocket.
- **travis-ci/events** - Checks that Mbed OS compiles and run events tests.
- **travis-ci/gitattributestest** - Checks there are no changes after clone. This checks that `.gitattributes` is used correctly.
- **travis-ci/licence_check** - Checks there is no GPL license text in the code.
- **travis-ci/licence_check** - Checks only a permissive license in the files, including SPDX identifier.
Copy link
Contributor

Choose a reason for hiding this comment

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

I think i missed a bit:

Checks that there is only a permissive license in the files,

@0xc0170
Copy link
Contributor Author

0xc0170 commented Feb 24, 2020

Fixed as well

Copy link
Contributor

@AnotherButler AnotherButler left a comment

Choose a reason for hiding this comment

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

Thanks for the PR 👍

@AnotherButler AnotherButler merged commit 1d59be0 into ARMmbed:development Feb 25, 2020
AnotherButler pushed a commit that referenced this pull request Feb 25, 2020
Apply changes from PR #1235 to v5.15.
AnotherButler pushed a commit that referenced this pull request Feb 25, 2020
Apply changes from PR #1235 to v5.15.
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.

3 participants