{"id":13474170,"url":"https://github.com/devblackops/github-action-psscriptanalyzer","last_synced_at":"2025-04-13T05:34:11.849Z","repository":{"id":33919071,"uuid":"163457538","full_name":"devblackops/github-action-psscriptanalyzer","owner":"devblackops","description":"GitHub Action to run PSScriptAnalyzer static code analysis","archived":false,"fork":false,"pushed_at":"2022-10-01T08:37:53.000Z","size":209,"stargazers_count":74,"open_issues_count":7,"forks_count":14,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-07T21:50:03.529Z","etag":null,"topics":["github-actions","powershell","psscriptanalyzer"],"latest_commit_sha":null,"homepage":null,"language":"PowerShell","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/devblackops.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":"devblackops","patreon":"devblackops"}},"created_at":"2018-12-28T23:25:02.000Z","updated_at":"2025-03-01T23:07:59.000Z","dependencies_parsed_at":"2023-01-11T20:41:51.769Z","dependency_job_id":null,"html_url":"https://github.com/devblackops/github-action-psscriptanalyzer","commit_stats":{"total_commits":68,"total_committers":6,"mean_commits":"11.333333333333334","dds":0.2941176470588235,"last_synced_commit":"854038567344559afaaa8ccb7a014452b99d86ee"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devblackops%2Fgithub-action-psscriptanalyzer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devblackops%2Fgithub-action-psscriptanalyzer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devblackops%2Fgithub-action-psscriptanalyzer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devblackops%2Fgithub-action-psscriptanalyzer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devblackops","download_url":"https://codeload.github.com/devblackops/github-action-psscriptanalyzer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248670520,"owners_count":21142896,"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","powershell","psscriptanalyzer"],"created_at":"2024-07-31T16:01:10.061Z","updated_at":"2025-04-13T05:34:11.546Z","avatar_url":"https://github.com/devblackops.png","language":"PowerShell","funding_links":["https://github.com/sponsors/devblackops","https://patreon.com/devblackops"],"categories":["Community Resources","PowerShell","Uncategorized"],"sub_categories":["Testing and Linting","Static Analysis","Uncategorized"],"readme":"# github-action-psscriptanalyzer\n\n[![GitHub Actions Status][github-actions-badge]][github-actions-build]\n\n[GitHub Action](https://github.com/features/actions) to run [PSScriptAnalyzer](https://github.com/PowerShell/PSScriptAnalyzer) static code analysis checks on PowerShell for [Pull Requests](https://help.github.com/articles/about-pull-requests/).\n\n## Success Criteria\n\nBy default, this action will succeed if **zero** PSScriptAnalyzer **errors** and **warnings** are found.\nFailing on errors, warnings, or informational issues can be configured. See [Usage](#Usage) below.\nThe sending of comments back to the PR if the action fails can be disabled if desired.\n\n## Usage\n\n### Basic\n\nBasic configuration that will run PSSA and fail on errors or warnings, and send a comment back to the PR with a summary.\nNote, that `repoToken` is required for sending comments back.\n\n```yaml\nname: CI\non: [pull_request]\njobs:\n  lint:\n    name: Run PSSA\n    runs-on: ubuntu-latest\n    steps:\n    - uses: actions/checkout@v2\n    - name: lint\n      uses: devblackops/github-action-psscriptanalyzer@master\n      with:\n        repoToken: ${{ secrets.GITHUB_TOKEN }}\n```\n\n### Advanced\n\nAdvanced configuration that will run PSSA only in the `MyModule` directory, with custom PSSA settings, and fail on errors, warnings, or informational issues.\nA comment back to the PR with the PSSA summary will also be sent if any issues were detected.\n\n```yaml\nname: CI\non: [pull_request]\njobs:\n  lint:\n    name: Run PSSA\n    runs-on: ubuntu-latest\n    steps:\n    - uses: actions/checkout@v2\n    - name: lint\n      uses: devblackops/github-action-psscriptanalyzer@master\n      with:\n        rootPath: MyModule\n        settingsPath: pssa_settings.psd1\n        sendComment: true\n        repoToken: ${{ secrets.GITHUB_TOKEN }}\n        failOnErrors: true\n        failOnWarnings: true\n        failOnInfos: true\n```\n\n### Docker\n\nUse the Docker Hub version of the Action instead of building the container during the check.\n\n```yaml\nname: CI\non: [pull_request]\njobs:\n  lint:\n    name: Run PSSA\n    runs-on: ubuntu-latest\n    steps:\n    - uses: actions/checkout@v2\n    - name: lint\n      uses: docker://devblackops/github-action-psscriptanalyzer:2.3.0\n      with:\n        repoToken: ${{ secrets.GITHUB_TOKEN }}\n```\n\n## Inputs\n\n| Name | Default | Description |\n|------|---------|-------------|\n| rootPath       | \\\u003cnone\u003e  | The root directory to run PSScriptAnalyzer on. By default, this is the root of the repository.\n| settingsPath   | \\\u003cnone\u003e  | The path to a PSScriptAnalyser settings file to control rules to execute.\n| sendComment    | true  | Enable/disable sending comments with PSScriptAnalyzer results back to PR.\n| repoToken      | \\\u003cnone\u003e  | GitHub token the action will use to send comments back to PR with. Use `${{ secrets.GITHUB_TOKEN }}`.\n| failOnErrors   | true  | Enable/disable failing the action on PSScriptAnalyzer error items.\n| failOnWarnings | true  | Enable/disable failing the action on PSScriptAnalyzer warning items.\n| failOnInfos    | false | Enable/disable failing the action on PSScriptAnalyzer informational items.\n\n## Example\n\n![](media/example.png)\n\n[github-actions-badge]: https://github.com/devblackops/github-action-psscriptanalyzer/workflows/CI/badge.svg\n[github-actions-build]: https://github.com/devblackops/github-action-psscriptanalyzer/actions\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevblackops%2Fgithub-action-psscriptanalyzer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevblackops%2Fgithub-action-psscriptanalyzer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevblackops%2Fgithub-action-psscriptanalyzer/lists"}