{"id":30456441,"url":"https://github.com/paulrosset/linter-farch","last_synced_at":"2026-03-15T16:31:37.850Z","repository":{"id":57290263,"uuid":"130246875","full_name":"PaulRosset/linter-farch","owner":"PaulRosset","description":"Make sure the filenames stay the same, control them! 👁 ","archived":false,"fork":false,"pushed_at":"2018-07-02T21:51:35.000Z","size":333,"stargazers_count":103,"open_issues_count":3,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-24T20:14:25.263Z","etag":null,"topics":["architecture","cli","filename","linter"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/PaulRosset.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}},"created_at":"2018-04-19T16:59:00.000Z","updated_at":"2023-04-30T14:40:02.000Z","dependencies_parsed_at":"2022-08-24T22:11:45.629Z","dependency_job_id":null,"html_url":"https://github.com/PaulRosset/linter-farch","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/PaulRosset/linter-farch","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulRosset%2Flinter-farch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulRosset%2Flinter-farch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulRosset%2Flinter-farch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulRosset%2Flinter-farch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PaulRosset","download_url":"https://codeload.github.com/PaulRosset/linter-farch/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulRosset%2Flinter-farch/sbom","scorecard":{"id":108451,"data":{"date":"2025-08-11","repo":{"name":"github.com/PaulRosset/linter-farch","commit":"6aa8bacbc5aab54238894e4f00089c9734cb43b5"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"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":"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":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"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":"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":"Dangerous-Workflow","score":-1,"reason":"no workflows found","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":"Code-Review","score":0,"reason":"Found 0/30 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":"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":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"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":"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":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"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":"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"}}]},"last_synced_at":"2025-08-15T11:34:21.028Z","repository_id":57290263,"created_at":"2025-08-15T11:34:21.028Z","updated_at":"2025-08-15T11:34:21.028Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279001114,"owners_count":26083021,"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-09T02:00:07.460Z","response_time":59,"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":["architecture","cli","filename","linter"],"created_at":"2025-08-23T16:33:04.269Z","updated_at":"2025-10-09T09:14:12.167Z","avatar_url":"https://github.com/PaulRosset.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n\t\u003cbr\u003e\n\t\u003cbr\u003e\n\t\u003cimg width=\"320\" src=\"media/logo.png\" alt=\"farch\"\u003e\n\t\u003cbr\u003e\n\t\u003cbr\u003e\n\t\u003cbr\u003e\n\u003c/h1\u003e\n\n\u003e Make sure the file-names stay the same, control them! 👁\n\n[![Travis CI Build Status](https://travis-ci.org/PaulRosset/linter-farch.svg?branch=master)](https://travis-ci.org/PaulRosset/linter-farch)\n[![npm version](https://badge.fury.io/js/linter-farch.svg)](https://badge.fury.io/js/linter-farch)\n[![Code Coverage](https://img.shields.io/codecov/c/github/PaulRosset/linter-farch.svg)](https://travis-ci.org/PaulRosset/linter-farch)\n\n## Motivation\n\nMore and more frameworks that have been created recently gave the possibility to the user to write content in markdown, like [Gatsby](https://github.com/gatsbyjs/gatsby) or [Docusaurus](https://github.com/facebook/docusaurus), but sometimes if you collaborate with multiples people on these markdown files, keeping a clean file-name is more important than ever. That's why I created this tiny linter to force people to respect a file-name architecture in order the keep everything clean and understandable.  \nOf course, many other usages can be considered.\n\n## Install\n\n```sh\nyarn add --dev linter-farch\n```\n\n## Usage\n\nOnce installed, a small and quick configuration is needed in the `package.json` file.  \nThe `package.json` file is used here, to avoid creating another file with a purpose of configuration.\n\n### Configuration:\n\nFor the configuration, two possibles way can be taken, the first is the `package.json` file like below (essentially for the JS project and if you don't want to create another config file):\n\nIn the `package.json` file:\n\n```json\n{\n  \"farch\": {\n    \"src\": \"([a-z]*-[0-9]{4})[.]*[a-z]*\",\n    \"src/utilities\": \"[a-z]*\",\n    \"src/utilities/*.js\": \"[a-z]\"\n  }\n}\n```\n\n\u003e You can use [`glob`](http://man7.org/linux/man-pages/man3/glob.3.html) as key/path to provide more flexibility to capture the wanted files.\n\n* Creating regex can be hard or simply boring, that's why you can simply put template placeholder like this:\n\n```json\n{\n  \"farch\": {\n    \"src\": \"([a-z]*-[0-9]{4})[.]*[a-z]*\",\n    \"src/utilities\": [\"LOWER_CAMEL_CASE_JS\", \"[a-z]*\"],\n    \"src/utilities/*.js\": \"[a-z]\"\n  }\n}\n```\n\nYou can find any template placeholder already created [here](https://github.com/PaulRosset/linter-farch/blob/master/src/template.js), feel free to contribute by adding more template/placeholder regex. The keys have to be of the following form: \"XXX*XXX_XXX_YY\", where \\_XXX* is the name and _YY_ the extension of the file that we want to test.\n\n---\n\nBut, there is still the possibility to create a `farch.json` config file at the root of the project, essentially for the non-js project or if you don't want to put the configuration in your `package.json`.\n\n```json\n{\n  \"farch\": {\n    \"src\": \"([a-z]*-[0-9]{4})[.]*[a-z]*\",\n    \"src/utilities\": \"[a-z]*\"\n  }\n}\n```\n\n\u003e `farch.json` file have the priority over the `package.json` file.\n\nInside the `farch` property, insert the directory that you want to test:  \nPass as `key`, the path from the root directory to the target directory, then in value pass `regex` to match.\n\n**Then, you are all set!**\n\n### Execution\n\nTo avoid creating tons of rules if you have a lot of directory nested and they apply to the same assertion you can pass `-R`, hence it will recursively check all the directory.\n\nAt the root of your project:\n\n```sh\nnpx farch\n```\n\nor\n\nInsert it in your `package.json` file:\n\n```json\n{\n  \"scripts\": {\n    \"test\": \"farch ((-R))\"\n  }\n}\n```\n\n**And run `CI` on it !**\n\n### Output\n\n\u003cdiv align=\"center\"\u003e\n\t\u003cimg src=\"media/demo1.png\" width=\"320\" alt=\"output-farch\"/\u003e\n\u003c/div\u003e\n\n## License\n\nMIT Paul Rosset\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaulrosset%2Flinter-farch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpaulrosset%2Flinter-farch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaulrosset%2Flinter-farch/lists"}