Check missing license header
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 210
- Forks
- 36
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 2
Description
If a file has the correct copyright header but misses a license header, the copyright-checker.sh script, which is used as a pre-commit hook, currently doesn't check and try to add the license, e.g.,
#!/usr/bin/env bash
# Copyright (c) 2022 - 2023, Oracle and/or its affiliates. All rights reserved.
# ...
passes the pre-commit hook test.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading scripts/dev_scripts/copyright-checker.sh and trace how the pre-commit hook checks and adds headers. Reproduce the shown file case, then update the checker so a correct copyright header without a license header is detected and handled; the pre-commit hook should reject or fix that case as intended.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- bash
- Domain
- ci-cd, tooling
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 48/100