diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index a506e1e..407cfad 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1 +1 @@ -* @github/ospo-github-actions +* @zkoppert @jmeridth diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index eb56275..69e0437 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -2,7 +2,7 @@ blank_issues_enabled: false contact_links: - name: Ask a question - url: https://github.com/github/cleanowners/discussions/new + url: https://github.com/github-community-projects/cleanowners/discussions/new about: Ask a question or start a discussion - name: GitHub OSPO GitHub Action Overall Issue url: https://github.com/github/github-ospo/issues/new diff --git a/.github/linters/.python-lint b/.github/linters/.python-lint index 1856f61..e9542b6 100644 --- a/.github/linters/.python-lint +++ b/.github/linters/.python-lint @@ -99,10 +99,6 @@ recursive=no # source root. source-roots= -# When enabled, pylint would attempt to guess common misconfiguration and emit -# user-friendly hints instead of false-positive error messages. -suggestion-mode=yes - # Allow loading of arbitrary C extensions. Extensions are imported into the # active Python interpreter and may run arbitrary code. unsafe-load-any-extension=no diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index f78f37f..7258072 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -20,8 +20,3 @@ examples: "feat: add new logger" or "fix: remove unused imports" - [ ] If documentation is needed for this change, has that been included in this pull request - [ ] run `make lint` and fix any issues that you have introduced - [ ] run `make test` and ensure you have test coverage for the lines you are introducing -- [ ] If publishing new data to the public (scorecards, security scan results, code quality results, live dashboards, etc.), please request review from `@jeffrey-luszcz` - -### Reviewer - -- [ ] Label as either `fix`, `documentation`, `enhancement`, `infrastructure`, `maintenance` or `breaking` diff --git a/.github/workflows/contributors_report.yaml b/.github/workflows/contributors_report.yaml index 1809c85..8251daf 100644 --- a/.github/workflows/contributors_report.yaml +++ b/.github/workflows/contributors_report.yaml @@ -35,7 +35,7 @@ jobs: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} START_DATE: ${{ env.START_DATE }} END_DATE: ${{ env.END_DATE }} - REPOSITORY: github/cleanowners + REPOSITORY: github-community-projects/cleanowners SPONSOR_INFO: "true" - name: Create issue diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 8f753e2..0621ef9 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -19,11 +19,11 @@ All types of contributions are encouraged and valued. See the [Table of Contents ## I Have a Question -Before you ask a question, it is best to search for existing [Issues](https://github.com/github/cleanowners/issues) that might help you. In case you have found a suitable issue and still need clarification, you can write your question in this issue. +Before you ask a question, it is best to search for existing [Issues](https://github.com/github-community-projects/cleanowners/issues) that might help you. In case you have found a suitable issue and still need clarification, you can write your question in this issue. If you then still feel the need to ask a question and need clarification, we recommend the following: -- Open an [Issue](https://github.com/github/cleanowners/issues/new). +- Open an [Issue](https://github.com/github-community-projects/cleanowners/issues/new). - Provide as much context as you can about what you're running into. - Provide project and platform versions (nodejs, npm, etc), depending on what seems relevant. @@ -45,7 +45,7 @@ A good bug report shouldn't leave others needing to chase you up for more inform - Make sure that you are using the latest version. - Determine if your bug is really a bug and not an error on your side e.g. using incompatible environment components/versions (Make sure that you have read the documentation. If you are looking for support, you might want to check [this section](#i-have-a-question)). -- To see if other users have experienced (and potentially already solved) the same issue you are having, check if there is not already a bug report existing for your bug or error in the [bug tracker](https://github.com/github/cleanowners/issues). +- To see if other users have experienced (and potentially already solved) the same issue you are having, check if there is not already a bug report existing for your bug or error in the [bug tracker](https://github.com/github-community-projects/cleanowners/issues). - Collect information about the bug: - Stack trace (Traceback) - OS, Platform and Version (Windows, Linux, macOS, x86, ARM) @@ -57,7 +57,7 @@ A good bug report shouldn't leave others needing to chase you up for more inform ### How Do I Submit a Good Bug Report? -Please submit a bug report using our [GitHub Issues template](https://github.com/github/cleanowners/issues/new?template=bug_report.yml). +Please submit a bug report using our [GitHub Issues template](https://github.com/github-community-projects/cleanowners/issues/new?template=bug_report.yml). ## Suggesting Enhancements @@ -69,14 +69,14 @@ This section guides you through submitting an enhancement suggestion for cleanow - Make sure that you are using the latest version. - Read the documentation carefully and find out if the functionality is already covered, maybe by an individual configuration. -- Perform a [search](https://github.com/github/cleanowners/issues) to see if the enhancement has already been suggested. If it has, add a comment to the existing issue instead of opening a new one. +- Perform a [search](https://github.com/github-community-projects/cleanowners/issues) to see if the enhancement has already been suggested. If it has, add a comment to the existing issue instead of opening a new one. - Find out whether your idea fits with the scope and aims of the project. It's up to you to make a strong case to convince the project's developers of the merits of this feature or to develop the feature yourself and contribute it to the project. ### How Do I Submit a Good Enhancement Suggestion? -Please submit an enhancement suggestion using our [GitHub Issues template](https://github.com/github/cleanowners/issues/new?template=feature_request.yml). +Please submit an enhancement suggestion using our [GitHub Issues template](https://github.com/github-community-projects/cleanowners/issues/new?template=feature_request.yml). ### Pull Request Standards @@ -86,4 +86,4 @@ We are using [Conventional Commits](https://www.conventionalcommits.org/en/v1.0. Releases are automated if a pull request is labelled with our [semver related labels](.github/release-drafter.yml) or with the `vuln` or `release` labels. -You can also manually initiate a release you can do so through the GitHub Actions UI. If you have permissions to do so, you can navigate to the [Actions tab](https://github.com/github/cleanowners/actions/workflows/release.yml) and select the `Run workflow` button. This will allow you to select the branch to release from and the version to release. +You can also manually initiate a release you can do so through the GitHub Actions UI. If you have permissions to do so, you can navigate to the [Actions tab](https://github.com/github-community-projects/cleanowners/actions/workflows/release.yml) and select the `Run workflow` button. This will allow you to select the branch to release from and the version to release. diff --git a/Dockerfile b/Dockerfile index 5abfca4..d9471af 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,7 +2,7 @@ #checkov:skip=CKV_DOCKER_3 #trivy:ignore:AVD-DS-0002 FROM python:3.14.0-slim@sha256:0aecac02dc3d4c5dbb024b753af084cafe41f5416e02193f1ce345d671ec966e -LABEL org.opencontainers.image.source https://github.com/github/cleanowners +LABEL org.opencontainers.image.source https://github.com/github-community-projects/cleanowners WORKDIR /action/workspace COPY requirements.txt *.py /action/workspace/ diff --git a/README.md b/README.md index 15aa61f..eccd15b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Cleanowners action -[![CodeQL](https://github.com/github/cleanowners/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/github/cleanowners/actions/workflows/github-code-scanning/codeql) [![Lint Code Base](https://github.com/github/cleanowners/actions/workflows/super-linter.yaml/badge.svg)](https://github.com/github/cleanowners/actions/workflows/super-linter.yaml) [![Python package](https://github.com/github/cleanowners/actions/workflows/python-ci.yml/badge.svg)](https://github.com/github/cleanowners/actions/workflows/python-ci.yml) [![Docker Image CI](https://github.com/github/cleanowners/actions/workflows/docker-ci.yml/badge.svg)](https://github.com/github/cleanowners/actions/workflows/docker-ci.yml)[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/github/cleanowners/badge)](https://scorecard.dev/viewer/?uri=github.com/github/cleanowners) +[![CodeQL](https://github.com/github-community-projects/cleanowners/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/github-community-projects/cleanowners/actions/workflows/github-code-scanning/codeql) [![Lint Code Base](https://github.com/github-community-projects/cleanowners/actions/workflows/super-linter.yaml/badge.svg)](https://github.com/github-community-projects/cleanowners/actions/workflows/super-linter.yaml) [![Python package](https://github.com/github-community-projects/cleanowners/actions/workflows/python-ci.yml/badge.svg)](https://github.com/github-community-projects/cleanowners/actions/workflows/python-ci.yml) [![Docker Image CI](https://github.com/github-community-projects/cleanowners/actions/workflows/docker-ci.yml/badge.svg)](https://github.com/github-community-projects/cleanowners/actions/workflows/docker-ci.yml)[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/github-community-projects/cleanowners/badge)](https://scorecard.dev/viewer/?uri=github.com/github-community-projects/cleanowners) Cleanowners is a GitHub Action that is designed to help keep `CODEOWNERS` files current by removing users that are no longer a part of the organization. This is helpful for companies that are looking to remove outdated information in the `CODEOWNERS` file. This action can be paired with other `CODEOWNERS` related actions to suggest new owners or lint `CODEOWNERS` files to ensure accuracy. @@ -10,7 +10,7 @@ This action was developed by the GitHub OSPO for our own use and developed in a ## Support -If you need support using this project or have questions about it, please [open up an issue in this repository](https://github.com/github/cleanowners/issues). Requests made directly to GitHub staff or support team will be redirected here to open an issue. GitHub SLA's and support/services contracts do not apply to this repository. +If you need support using this project or have questions about it, please [open up an issue in this repository](https://github.com/github-community-projects/cleanowners/issues). Requests made directly to GitHub staff or support team will be redirected here to open an issue. GitHub SLA's and support/services contracts do not apply to this repository. ### OSPO GitHub Actions as a Whole @@ -52,14 +52,14 @@ This action can be configured to authenticate with GitHub App Installation or Pe #### Other Configuration Options -| field | required | default | description | -| ------------------- | ----------------------------------------------- | ------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `GH_ENTERPRISE_URL` | False | "" | The `GH_ENTERPRISE_URL` is used to connect to an enterprise server instance of GitHub. github.com users should not enter anything here. | -| `ORGANIZATION` | Required to have `ORGANIZATION` or `REPOSITORY` | | The name of the GitHub organization which you want this action to work from. ie. github.com/github would be `github` | -| `REPOSITORY` | Required to have `ORGANIZATION` or `REPOSITORY` | | The name of the repository and organization which you want this action to work from. ie. `github/cleanowners` or a comma separated list of multiple repositories `github/cleanowners,super-linter/super-linter` | -| `EXEMPT_REPOS` | False | "" | These repositories will be exempt from this action. ex: If my org is set to `github` then I might want to exempt a few of the repos but get the rest by setting `EXEMPT_REPOS` to `github/cleanowners,github/contributors` | -| `DRY_RUN` | False | False | If set to true, this action will not create any pull requests. It will only log the repositories that could have the `CODEOWNERS` file updated. This is useful for testing or discovering the scope of this issue in your organization. | -| `ISSUE_REPORT` | False | False | If set to true, this action will create an issue in the repository with the report on the repositories that had users removed from the `CODEOWNERS` file. | +| field | required | default | description | +| ------------------- | ----------------------------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `GH_ENTERPRISE_URL` | False | "" | The `GH_ENTERPRISE_URL` is used to connect to an enterprise server instance of GitHub. github.com users should not enter anything here. | +| `ORGANIZATION` | Required to have `ORGANIZATION` or `REPOSITORY` | | The name of the GitHub organization which you want this action to work from. ie. github.com/github would be `github` | +| `REPOSITORY` | Required to have `ORGANIZATION` or `REPOSITORY` | | The name of the repository and organization which you want this action to work from. ie. `github-community-projects/cleanowners` or a comma separated list of multiple repositories `github-community-projects/cleanowners,super-linter/super-linter` | +| `EXEMPT_REPOS` | False | "" | These repositories will be exempt from this action. ex: If my org is set to `github` then I might want to exempt a few of the repos but get the rest by setting `EXEMPT_REPOS` to `github-community-projects/cleanowners,github/contributors` | +| `DRY_RUN` | False | False | If set to true, this action will not create any pull requests. It will only log the repositories that could have the `CODEOWNERS` file updated. This is useful for testing or discovering the scope of this issue in your organization. | +| `ISSUE_REPORT` | False | False | If set to true, this action will create an issue in the repository with the report on the repositories that had users removed from the `CODEOWNERS` file. | ### Example workflows @@ -85,7 +85,7 @@ jobs: steps: - name: Run cleanowners action - uses: github/cleanowners@v1 + uses: github-community-projects/cleanowners@v2 env: GH_TOKEN: ${{ secrets.GH_TOKEN }} ORGANIZATION: @@ -113,7 +113,7 @@ jobs: steps: - name: Run cleanowners action - uses: github/cleanowners@v1 + uses: github-community-projects/cleanowners@v2 env: GH_TOKEN: ${{ secrets.GH_TOKEN }} ORGANIZATION: @@ -152,7 +152,7 @@ jobs: steps: - name: Run cleanowners action - uses: github/cleanowners@v1 + uses: github-community-projects/cleanowners@v2 env: GH_APP_ID: ${{ secrets.GH_APP_ID }} GH_APP_INSTALLATION_ID: ${{ secrets.GH_APP_INSTALLATION_ID }} diff --git a/action.yml b/action.yml index 4591402..9c828ae 100644 --- a/action.yml +++ b/action.yml @@ -4,7 +4,7 @@ author: "github" description: "A GitHub Action to suggest removal of non-organization members from CODEOWNERS files." runs: using: "docker" - image: "docker://ghcr.io/github/cleanowners:v1" + image: "docker://ghcr.io/github-community-projects/cleanowners:v2" branding: icon: "bell" color: "orange"