{"id":16552397,"url":"https://github.com/dieghernan/cran-status-check","last_synced_at":"2025-05-12T18:02:12.527Z","repository":{"id":98401392,"uuid":"599240384","full_name":"dieghernan/cran-status-check","owner":"dieghernan","description":"GitHub Action for checking R packages status on CRAN","archived":false,"fork":false,"pushed_at":"2025-03-03T15:04:21.000Z","size":57,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-13T14:52:20.345Z","etag":null,"topics":["actions","continuous-integration","cran","github-actions","r-development","r-package","rstats","rstats-package"],"latest_commit_sha":null,"homepage":"https://github.com/marketplace/actions/cran-status-check","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dieghernan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-02-08T18:34:20.000Z","updated_at":"2025-03-03T15:04:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"23b3d444-47dc-46b3-934c-d3be47738cda","html_url":"https://github.com/dieghernan/cran-status-check","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dieghernan%2Fcran-status-check","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dieghernan%2Fcran-status-check/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dieghernan%2Fcran-status-check/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dieghernan%2Fcran-status-check/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dieghernan","download_url":"https://codeload.github.com/dieghernan/cran-status-check/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253794636,"owners_count":21965484,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["actions","continuous-integration","cran","github-actions","r-development","r-package","rstats","rstats-package"],"created_at":"2024-10-11T19:44:43.643Z","updated_at":"2025-05-12T18:02:12.440Z","avatar_url":"https://github.com/dieghernan.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cran-status-check\r\n\r\n![latest-version](https://img.shields.io/github/v/release/dieghernan/cran-status-check)\r\n\r\nThis action checks the CRAN status of a **R** package and optionally creates an\r\nissue or make the action fail. Combined with CRON (see [how to set periodic runs\r\non GH\r\nActions](https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#schedule)),\r\na **R** package developer can verify regularly if the package needs attention.\r\n\r\n## Basic configuration\r\n\r\nCreate a file named `cran-status-check.yml` on a repo in the usual path for GH\r\nactions (`.github/workflows`) with the following content:\r\n\r\n``` yaml\r\nname: check-cran-status\r\n\r\non:\r\n  push:\r\n    branches: [main, master]\r\n  schedule:\r\n    - cron: '0 6 * * 1,4' # Runs at 06:00 on Monday and Thursday, check https://crontab.guru/\r\njobs:\r\n  check:\r\n    runs-on: ubuntu-latest\r\n    permissions: write-all # This line is important for creating issues, should be on jobs or global\r\n    env:\r\n      GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}\r\n\r\n    steps:\r\n      - name: Checkout\r\n        uses: actions/checkout@v3\r\n        \r\n      - name: Check\r\n        uses: dieghernan/cran-status-check@v2\r\n```\r\n\r\n## Inputs available\r\n\r\n### Package inputs\r\n\r\n-   `path`: Default value `'.'` (root of the repo). Path to the **R** package\r\n    root, if the package is not at the top level of the repository.\r\n\r\n    ``` yaml\r\n      - name: Check\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          path: \"Rpackage\"\r\n    ```\r\n\r\n-   `package`: Default value `''`. Name of the package to check. If provided, it\r\n    would have priority over the package on the repo defined on `path`. It is\r\n    useful for creating workflows than can check several packages\r\n\r\n    ``` yaml\r\n\r\n      - name: Check dplyr\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          package: \"dplyr\"\r\n\r\n      - name: Check ggplot2\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          package: \"ggplot2\"    \r\n    ```\r\n\r\n-   `statuses`: Default value `'WARN,ERROR'`. CRAN status to check. This is a\r\n    comma-separated string of statuses. Allowed statuses are `'NOTE'`, `'WARN'`,\r\n    and `'ERROR'`.\r\n\r\n    ``` yaml\r\n\r\n      - name: Check dplyr\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          package: \"dplyr\"\r\n\r\n      - name: Check ggplot2\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          package: \"ggplot2\"    \r\n    ```\r\n\r\n### Result reports\r\n\r\n-   `fail-on-error`: Default value `'false'`. Logical, should the action errors\r\n    if CRAN checks are not OK? This is useful for ensuring that subsequent steps\r\n    would be performed even if any of the packages to check throws an error.\r\n\r\n    ``` yaml\r\n\r\n      - name: Check a package not in CRAN\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          package: \"iamnotincran\"\r\n          fail-on-error: \"false\"\r\n\r\n      - name: Check igoR even if the previous step has failed but stop here\r\n        uses: dieghernan/cran-status-check@v2\r\n        with:\r\n          package: \"igoR\"\r\n          statuses: \"NOTE,WARN,ERROR\"\r\n          fail-on-error: \"true\"\r\n    ```\r\n\r\n-   `create-issue`: Default value `true` Logical, create an issue on CRAN failed\r\n    checks using\r\n    [create-issue-from-file](https://github.com/peter-evans/create-issue-from-file)\r\n    action.\r\n\r\n-   `issue-assignees`: Default value `''`. Whom should the issue be assigned to\r\n    if errors are encountered in the CRAN status checks? This is a\r\n    comma-separated string of GitHub usernames. If undefined or empty, no\r\n    assignments are made. Check also\r\n    [create-issue-from-file](https://github.com/peter-evans/create-issue-from-file)\r\n    action.\r\n\r\n    ``` yaml\r\n\r\n    -  name: Check igoR and create issue \r\n       uses: dieghernan/cran-status-check@v2\r\n       with: \r\n         package: \"igoR\" \r\n         statuses: \"NOTE,WARN,ERROR\" \r\n         fail-on-error: \"true\"\r\n         create-issue: \"true\" \r\n         issue-assignees: \"dieghernan,johndoe\"\r\n    ```\r\n\r\n## Outputs\r\n\r\n-   The action would produce a report with a summary of the check\r\n\r\n-   If `create-issue: \"true\"` (the default value) and the action found an error,\r\n    it would create an issue on the repo and (if provided) it would assign it to\r\n    the users specified on `issue-assignees`.\r\n\r\n-   if `fail-on-error: \"true\"` (not activated by default) the action would fail,\r\n    and GitHub would send a notification to the repo owner following the\r\n    standard process of GH Actions.\r\n\r\n## Derived Work Notice\r\n\r\nThis workflow is derived from\r\n[cran-status.yml](https://github.com/pharmaverse/admiralci/blob/61347fe11955297818b3ca7814fc7328f2ad7840/.github/workflows/cran-status.yml)\r\nby [pharmaverse/admiralci\r\ncontributors](https://github.com/pharmaverse/admiralci/graphs/contributors):\r\n\r\n\u003e Copyright 2021 F. Hoffmann-La Roche AG and GlaxoSmithKline LLC\r\n\u003e\r\n\u003e Licensed under the Apache License, Version 2.0 (the \"License\"); you may not\r\n\u003e use this file except in compliance with the License. You may obtain a copy of\r\n\u003e the License at\r\n\u003e\r\n\u003e \u003chttp://www.apache.org/licenses/LICENSE-2.0\u003e\r\n\u003e\r\n\u003e Unless required by applicable law or agreed to in writing, software\r\n\u003e distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\r\n\u003e WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the\r\n\u003e License for the specific language governing permissions and limitations under\r\n\u003e the License.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdieghernan%2Fcran-status-check","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdieghernan%2Fcran-status-check","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdieghernan%2Fcran-status-check/lists"}