{"id":31532653,"url":"https://github.com/batista/lint-filenames","last_synced_at":"2025-10-04T03:57:26.600Z","repository":{"id":36989968,"uuid":"313408631","full_name":"batista/lint-filenames","owner":"batista","description":"A simple github action that validates if all files in a given folder match the given regex pattern.","archived":false,"fork":false,"pushed_at":"2024-05-15T00:23:55.000Z","size":1426,"stargazers_count":31,"open_issues_count":14,"forks_count":6,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-29T23:21:37.931Z","etag":null,"topics":["actions","filenames","folder-tooling","github-actions","lint","pattern-matching","quality-assurance","tooling"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/batista.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":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-11-16T19:40:24.000Z","updated_at":"2024-06-18T09:14:53.000Z","dependencies_parsed_at":"2024-05-02T01:34:13.028Z","dependency_job_id":"e0baf40c-eb24-4813-9203-9d13f12e83ab","html_url":"https://github.com/batista/lint-filenames","commit_stats":{"total_commits":88,"total_committers":3,"mean_commits":"29.333333333333332","dds":"0.20454545454545459","last_synced_commit":"831feeb91579a17faad4cdbf45701e6e1b355cd2"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/batista/lint-filenames","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/batista%2Flint-filenames","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/batista%2Flint-filenames/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/batista%2Flint-filenames/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/batista%2Flint-filenames/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/batista","download_url":"https://codeload.github.com/batista/lint-filenames/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/batista%2Flint-filenames/sbom","scorecard":{"id":227205,"data":{"date":"2025-08-11","repo":{"name":"github.com/batista/lint-filenames","commit":"d6b5131a8d409324b6daf71ead679b7fab6384e7"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.4,"checks":[{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 1/16 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'actions' permission set to 'read': .github/workflows/codacy-analysis.yml:31","Info: jobLevel 'actions' permission set to 'read': .github/workflows/codeql-analysis.yml:18","Warn: no topLevel permission defined: .github/workflows/codacy-analysis.yml:1","Warn: no topLevel permission defined: .github/workflows/codeql-analysis.yml:1","Warn: no topLevel permission defined: .github/workflows/test.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":2,"reason":"dependency not pinned by hash detected -- score normalized to 2","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codacy-analysis.yml:35: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codacy-analysis.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/codacy-analysis.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codacy-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codacy-analysis.yml:55: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codacy-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:36: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/codeql-analysis.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/codeql-analysis.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/test.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/test.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/test.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:36: update your workflow using https://app.stepsecurity.io/secureworkflow/batista/lint-filenames/test.yml/master?enable=pin","Info:   0 out of  10 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned","Info:   1 out of   1 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":7,"reason":"SAST tool detected but not run on all commits","details":["Info: SAST configuration detected: CodeQL","Warn: 0 commits out of 29 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"16 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-7r3h-m5j6-3q42","Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-h5c3-5r3r-rr8q","Warn: Project is vulnerable to: GHSA-rmvr-2pp2-xj38","Warn: Project is vulnerable to: GHSA-xx4v-prfh-6cgc","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-17T04:02:07.308Z","repository_id":36989968,"created_at":"2025-08-17T04:02:07.308Z","updated_at":"2025-08-17T04:02:07.308Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278150304,"owners_count":25938354,"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","status":"online","status_checked_at":"2025-10-03T02:00:06.070Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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","filenames","folder-tooling","github-actions","lint","pattern-matching","quality-assurance","tooling"],"created_at":"2025-10-04T03:57:24.390Z","updated_at":"2025-10-04T03:57:26.593Z","avatar_url":"https://github.com/batista.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Lint Filenames action\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/batista/lint-filenames/actions?query=workflow%3Abuild-test+branch%3Amaster\"\u003e\u003cimg alt=\"build-test action status\" src=\"https://github.com/batista/lint-filenames/workflows/build-test/badge.svg?branch=master\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://github.com/batista/lint-filenames/actions?query=workflow%3ACodeQL+branch%3Amaster\"\u003e\u003cimg alt=\"code-ql action status\" src=\"https://github.com/batista/lint-filenames/workflows/CodeQL/badge.svg?branch=master\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://github.com/batista/lint-filenames/actions/workflows/codacy-analysis.yml\"\u003e\u003cimg alt=\"Codacy Security Scan\" src=\"https://github.com/batista/lint-filenames/actions/workflows/codacy-analysis.yml/badge.svg?branch=master\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://github.com/batista/lint-filenames/blob/main/LICENSE\"\u003e\u003cimg alt=\"license MIT\" src=\"https://img.shields.io/github/license/batista/lint-filenames\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n**Lint Filenames** is an simple github action to help you ensure certain patterns\nare followed in a given folder in your repository.\n\n![Sample Report](./assets/sample-report.png)\n\n## Inputs\n\n### `path`\n\n**Required** The path to a directory to check the filenames.\n\n### `pattern`\n\n**Required** The _escaped_ regex pattern to match for each of the files in the given directory.\n\n- _NOTE:_ the pattern needs to have all backslashes (`\\`) escaped, i.e. for each `\\` you need\n  to replace with `\\\\`.\n- Example: `/^\\d+\\.jpg$/` should be `/^\\\\d+\\\\.jpg$/`.\n\n_For more examples, see [`./__tests__/validate-filenames.test.ts`](./__tests__/validate-filenames.test.ts)._\n\n## Outputs\n\n### `total-files-analyzed`\n\nThe number of files analyzed.\n\n## Example usage\n\nto ensure all files match the pattern `/^.+\\..+$/` in the `my-files` directory, use the following:\n\n```yml\nuses: batista/lint-filenames@v1\nname: Validating my-folder filenames\nwith:\n  path: './my-folder'\n  pattern: '^.+\\\\..+$'\n```\n\n---\n\n## Development\n\nInstall the dependencies\n\n```bash\nnpm install\n```\n\nBuild the typescript and package it for distribution\n\n```bash\nnpm run build \u0026\u0026 npm run package\n```\n\nRun the tests :heavy_check_mark:\n\n```bash\nnpm test\n\n PASS  __tests__/validate-filenames.test.ts\n  Name of the group\n    ✓ 01 - Passes for any character files (10 ms)\n    ✓ 02 - Passes for `name.ext` files (1 ms)\n    ✓ 03 - Passes for `.dotfiles` (1 ms)\n    ✓ 04 - Passes for no `.dotfiles`\n    ✓ 05 - Passes for files with `a` in the name (1 ms)\n    ✓ 06 - Passes for json files `*.json` (1 ms)\n\nTest Suites: 1 passed, 1 total\nTests:       6 passed, 6 total\nSnapshots:   0 total\nTime:        0.559 s, estimated 2 s\nRan all test suites.\n\n```\n\n## Publish to a distribution branch\n\nActions are run from GitHub repos so we will checkin the packed dist folder.\n\nThen run [ncc](https://github.com/zeit/ncc) and push the results:\n\n```bash\n$ npm run package\n$ git add dist\n$ git commit -a -m \"prod dependencies\"\n$ git push origin releases/v1\n```\n\nYour action is now published! :rocket:\n\nSee the [versioning documentation](https://github.com/actions/toolkit/blob/master/docs/action-versioning.md)\n\n## Validate\n\nYou can now validate the action by referencing `./` in a workflow in your repo (see [test.yml](.github/workflows/test.yml))\n\n```yaml\nuses: ./\nwith:\n  path: './__tests__/test-files/06-json-files'\n  pattern: \"\\\\.json$\"\n```\n\nSee the [actions tab](https://github.com/batista/lint-filenames/actions) for runs of this action! :rocket:\n\n## Usage\n\nAfter testing you can [create a v1 tag](https://github.com/actions/toolkit/blob/master/docs/action-versioning.md) to reference the stable and latest V1 action\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbatista%2Flint-filenames","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbatista%2Flint-filenames","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbatista%2Flint-filenames/lists"}