{"id":18733514,"url":"https://github.com/insightsengineering/r-license-report","last_synced_at":"2025-04-12T18:31:43.310Z","repository":{"id":43722487,"uuid":"378669409","full_name":"insightsengineering/r-license-report","owner":"insightsengineering","description":"Github Action to generate an R Package Dependencies' License Report","archived":false,"fork":false,"pushed_at":"2024-03-15T15:40:56.000Z","size":89,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-26T12:51:13.836Z","etag":null,"topics":["github-actions","license-checking","r"],"latest_commit_sha":null,"homepage":"https://github.com/marketplace/actions/r-dependency-license-report","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/insightsengineering.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null}},"created_at":"2021-06-20T14:47:38.000Z","updated_at":"2024-11-20T17:27:48.000Z","dependencies_parsed_at":"2023-01-11T17:22:27.218Z","dependency_job_id":null,"html_url":"https://github.com/insightsengineering/r-license-report","commit_stats":{"total_commits":15,"total_committers":4,"mean_commits":3.75,"dds":0.2666666666666667,"last_synced_commit":"dddc3b175c5b62f93abc7fe37f770eb2ec95e0f2"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insightsengineering%2Fr-license-report","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insightsengineering%2Fr-license-report/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insightsengineering%2Fr-license-report/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/insightsengineering%2Fr-license-report/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/insightsengineering","download_url":"https://codeload.github.com/insightsengineering/r-license-report/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248613519,"owners_count":21133527,"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":["github-actions","license-checking","r"],"created_at":"2024-11-07T15:10:05.606Z","updated_at":"2025-04-12T18:31:42.960Z","avatar_url":"https://github.com/insightsengineering.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![SuperLinter](https://github.com/insightsengineering/r-license-report/actions/workflows/lint.yaml/badge.svg)](https://github.com/insightsengineering/r-license-report/actions/workflows/lint.yaml)\n[![License report action test](https://github.com/insightsengineering/r-license-report/actions/workflows/test.yaml/badge.svg)](https://github.com/insightsengineering/r-license-report/actions/workflows/test.yaml)\n\n\u003c!-- BEGIN_ACTION_DOC --\u003e\n# R Dependency License Report\n\n### Description\nA Github Action that generates a license report of an R package's dependencies for continuous compliance.\n\n### Action Type\nDocker\n\n### Author\nInsights Engineering\n\n### Inputs\n* `path`:\n\n  _Description_: Path to package's root\n\n  _Required_: `false`\n\n  _Default_: `.`\n\n* `regex`:\n\n  _Description_: Regex used for flagging packages with non-compliant licenses\n\n  _Required_: `false`\n\n  _Default_: `\"\"`\n\n* `fail`:\n\n  _Description_: Fail with a non-zero exit code if one or more dependencies are flagged by the regex\n\n  _Required_: `false`\n\n  _Default_: `True`\n\n* `rspm_snapshot_date`:\n\n  _Description_: RSPM snapshot date (in the YYYY-MM-DD format) for package metadata retrieval. Defaults to current date\n\n  _Required_: `false`\n\n  _Default_: `\"\"`\n\n* `bioc_release`:\n\n  _Description_: BioConductor release version for package metadata retrieval\n\n  _Required_: `false`\n\n  _Default_: `release`\n\n* `as_html`:\n\n  _Description_: Whether you also want the report as an `html` file\n\n  _Required_: `false`\n\n  _Default_: `false`\n\n### Outputs\nNone\n\u003c!-- END_ACTION_DOC --\u003e\n\n## Usage\n\nTo use this GitHub Action you will need to complete the following:\n\n* Create a new file in your repository called `.github/workflows/r-license-report.yml`\n* Copy the quickstart workflow from below into that new file, no extra configuration required\n* Commit that file to a new branch\n* Open up a pull request and observe the action working\n* Review the output of the action as needed\n\n### Quickstart\n\nIn your repository you should have a `.github/workflows/r-license-report.yml` folder with GitHub Action similar to below:\n\n```yaml\n---\nname: License Report\n\non:\n  push:\n    branches-ignore: [main]\n  pull_request:\n    branches: [main]\n\njobs:\n  license-report:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Checkout repo\n        uses: actions/checkout@v3\n      - name: License Report\n        uses: insightsengineering/r-license-report@v1\n```\n\n### Complete example\n\nThe following workflow is a complete example that highlights the available options in this Action:\n\n```yaml\n---\nname: License Compliance Check\n\non:\n  push:\n    branches-ignore: [main]\n  pull_request:\n    branches: [main]\n\njobs:\n  license-check:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Checkout repo\n        uses: actions/checkout@v3\n\n      - name: Generate License Report\n        uses: insightsengineering/r-license-report@v1\n        with:\n          # R package root path, in case your R package is within a subdirectory of the repo\n          path: \".\"\n          # A regular expression that can be used for matching and flagging non-compliant licenses\n          regex: \"^AGPL.*\"\n          # Fail the action if 1 or more matching non-compliant licenses are found\n          fail: true\n          # Select an RSPM snapshot date for CRAN dependency metadata retrieval\n          rspm_snapshot_date: \"2021-12-12\"\n          # Select a Bioconductor release version for BioC dependency metadata retrieval\n          bioc_release: \"3.14\"\n          # Whether you also want the report as an `html` file\n          as_html: true\n\n      - name: Upload PDF Report\n        uses: actions/upload-artifact@v2\n        with:\n          name: license-report.pdf\n          path: license-report.pdf\n```\n\nAn example of the output of the action can be seen below:\n![Screenshot with example output](example.png)\n\n## Standalone Usage\n\nThe underlying script used in this action can also be used as a standalone script, and can be used outside of this action (eg. in other CI/CD tools). Simply:\n\n- Download the script\n\n```bash\nwget https://raw.githubusercontent.com/insightsengineering/r-license-report/main/license-report.R\n```\n\n- Set execute permissions\n\n```bash\nchmod +x license-report.R\n```\n\n- Run the script\n\n```bash\n./license-report.R --help\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finsightsengineering%2Fr-license-report","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finsightsengineering%2Fr-license-report","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finsightsengineering%2Fr-license-report/lists"}