Skip to content

Commit

Permalink
feat(monorepo): add one-version, a strict dependency conformance tool…
Browse files Browse the repository at this point in the history
… for monorepos (#164)

This tool ensures that all workspaces in
your monorepo are using the same version of
a dependency, and also enforce strict
versioning strategy to ensure that all
dependencies are pinned to an exact
version.
  • Loading branch information
mpellegrini authored Oct 1, 2024
1 parent 8dd8d38 commit 56cc297
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 28 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/one-version-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: one-version-conformance-check
on:
pull_request:

jobs:
one-version-check:
name: One Version Check
runs-on: ubuntu-latest

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Prepare
uses: ./.github/composite-actions/prepare

- name: Run One Version check
run: pnpm run one-version:check
5 changes: 5 additions & 0 deletions one-version.config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"packageManager": "pnpm",
"versionStrategy": "pin",
"overrides": {}
}
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"clean": "turbo run clean",
"format": "prettier --write .",
"lint": "turbo run lint",
"one-version:check": "one-version check",
"prepare": "husky",
"test": "turbo run test",
"typecheck": "turbo run typecheck"
Expand All @@ -17,6 +18,7 @@
"del-cli": "5.1.0",
"husky": "9.1.6",
"lint-staged": "15.2.10",
"one-version": "0.2.0",
"prettier": "3.3.3",
"prettier-plugin-packagejson": "2.5.2",
"prettier-plugin-svelte": "3.2.6",
Expand Down
40 changes: 13 additions & 27 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion toolchain/eslint-config/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"@typescript-eslint/eslint-plugin": "8.7.0",
"@typescript-eslint/parser": "8.7.0",
"eslint": "9.11.1",
"eslint-config-prettier": "^9.1.0",
"eslint-config-prettier": "9.1.0",
"eslint-import-resolver-typescript": "3.6.3",
"eslint-plugin-deprecation": "3.0.0",
"eslint-plugin-eslint-comments": "3.2.0",
Expand Down

0 comments on commit 56cc297

Please sign in to comment.