diff --git a/.github/workflows/license.yml b/.github/workflows/license.yml new file mode 100644 index 00000000..03b43aec --- /dev/null +++ b/.github/workflows/license.yml @@ -0,0 +1,48 @@ +# MIT License +# +# Copyright (c) 2024 Zerocracy +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in all +# copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +# SOFTWARE. +--- +name: license +'on': + push: + branches: + - master + pull_request: + branches: + - master +jobs: + license: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + - shell: bash + run: | + header="Copyright (c) $(date +%Y) Zerocracy" + failed="false" + while IFS= read -r file; do + if ! grep -q "$header" "$file"; then + failed="true" + echo "⚠️ Copyright header is not found in: ${file}" + fi + done < <(find . -type f \( -name "*.sh" -o -name "*.rb" -o -name "*.yml" \) -print) + if [ "${failed}" = "true" ]; then + exit 1 + fi diff --git a/.github/workflows/zerocracy.yml b/.github/workflows/zerocracy.yml index 71db8ad6..17089d16 100644 --- a/.github/workflows/zerocracy.yml +++ b/.github/workflows/zerocracy.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/.rubocop.yml b/.rubocop.yml index d13f132b..ad1a9937 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/catch/catch_accepted_bug/catch-simple.yml b/judges/catch/catch_accepted_bug/catch-simple.yml index f0255690..7c30520e 100644 --- a/judges/catch/catch_accepted_bug/catch-simple.yml +++ b/judges/catch/catch_accepted_bug/catch-simple.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/catch/catch_accepted_bug/no-catch.yml b/judges/catch/catch_accepted_bug/no-catch.yml index fdc43211..eaf4680c 100644 --- a/judges/catch/catch_accepted_bug/no-catch.yml +++ b/judges/catch/catch_accepted_bug/no-catch.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/catch/catch_closed_issue/catch_closed_issue.yml b/judges/catch/catch_closed_issue/catch_closed_issue.yml index bde01711..47b710d4 100644 --- a/judges/catch/catch_closed_issue/catch_closed_issue.yml +++ b/judges/catch/catch_closed_issue/catch_closed_issue.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/communicate/send_github_message_award/send-it.yml b/judges/communicate/send_github_message_award/send-it.yml index e78a5f1e..499f3773 100644 --- a/judges/communicate/send_github_message_award/send-it.yml +++ b/judges/communicate/send_github_message_award/send-it.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/reward/reward_for_closed_issue/reward_for_closed_issue.yml b/judges/reward/reward_for_closed_issue/reward_for_closed_issue.yml index 557b17f4..cfe6ea08 100644 --- a/judges/reward/reward_for_closed_issue/reward_for_closed_issue.yml +++ b/judges/reward/reward_for_closed_issue/reward_for_closed_issue.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/reward/reward_for_good_bug/no-reward.yml b/judges/reward/reward_for_good_bug/no-reward.yml index 3011cef0..c98735c4 100644 --- a/judges/reward/reward_for_good_bug/no-reward.yml +++ b/judges/reward/reward_for_good_bug/no-reward.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/reward/reward_for_good_bug/simple-reward.yml b/judges/reward/reward_for_good_bug/simple-reward.yml index cdc3ead7..7cdea531 100644 --- a/judges/reward/reward_for_good_bug/simple-reward.yml +++ b/judges/reward/reward_for_good_bug/simple-reward.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/scan/scan_github_events/quick-scan.yml b/judges/scan/scan_github_events/quick-scan.yml index 85637737..81e4394e 100644 --- a/judges/scan/scan_github_events/quick-scan.yml +++ b/judges/scan/scan_github_events/quick-scan.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/judges/scan/scan_github_labels/find-labels.yml b/judges/scan/scan_github_labels/find-labels.yml index b2927cc6..20121e46 100644 --- a/judges/scan/scan_github_labels/find-labels.yml +++ b/judges/scan/scan_github_labels/find-labels.yml @@ -1,7 +1,9 @@ -# Copyright (c) 2024 Yegor Bugayenko +# MIT License +# +# Copyright (c) 2024 Zerocracy # # Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the 'Software'), to deal +# of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is @@ -10,7 +12,7 @@ # The above copyright notice and this permission notice shall be included in all # copies or substantial portions of the Software. # -# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER diff --git a/test/octo/test_fake_octokit.rb b/test/octo/test_fake_octokit.rb index 282b64a9..9013a55f 100644 --- a/test/octo/test_fake_octokit.rb +++ b/test/octo/test_fake_octokit.rb @@ -27,7 +27,7 @@ # Test. # Author:: Yegor Bugayenko (yegor256@gmail.com) -# Copyright:: Copyright (c) 2024 Yegor Bugayenko +# Copyright:: Copyright (c) 2024 Zerocracy # License:: MIT class TestFakeOctokit < Minitest::Test def test_rate_limit diff --git a/test/test_each_repo.rb b/test/test_each_repo.rb index 821385f2..27ace180 100644 --- a/test/test_each_repo.rb +++ b/test/test_each_repo.rb @@ -29,7 +29,7 @@ # Test. # Author:: Yegor Bugayenko (yegor256@gmail.com) -# Copyright:: Copyright (c) 2024 Yegor Bugayenko +# Copyright:: Copyright (c) 2024 Zerocracy # License:: MIT class TestEachRepo < Minitest::Test def test_simple_use diff --git a/test/test_octo.rb b/test/test_octo.rb index 758462ac..d0d396a1 100644 --- a/test/test_octo.rb +++ b/test/test_octo.rb @@ -28,7 +28,7 @@ # Test. # Author:: Yegor Bugayenko (yegor256@gmail.com) -# Copyright:: Copyright (c) 2024 Yegor Bugayenko +# Copyright:: Copyright (c) 2024 Zerocracy # License:: MIT class TestOcto < Minitest::Test def test_simple_use