Skip to content

Commit

Permalink
build: use nx
Browse files Browse the repository at this point in the history
  • Loading branch information
aladdin-add committed Oct 11, 2023
1 parent cf55787 commit a91d311
Show file tree
Hide file tree
Showing 8 changed files with 39 additions and 45 deletions.
30 changes: 15 additions & 15 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
{
enabledManagers: ['github-actions', 'npm'],
internalChecksFilter: 'strict',
labels: ['dependencies'],
dependencyDashboard: true,
dependencyDashboardLabels: ['dependencies', 'repo maintenance'],
major: {
// most majors will require some manual effort to upgrade to, so we don't want to create
// PRs automatically or else we'll just spam ourselves.
dependencyDashboardApproval: true,
},
// by default renovate will auto-rebase whenever the dep pranch falls behind main.
// this is annoying as it spams notifications and creates unnecessary action runs.
// instead only auto-rebase when conflicted, and we can trigger a manual rebase if required.
rebaseWhen: 'conflicted',
stabilityDays: 3,
enabledManagers: ["github-actions", "npm"],
internalChecksFilter: "strict",
labels: ["dependencies"],
dependencyDashboard: true,
dependencyDashboardLabels: ["dependencies", "repo maintenance"],
major: {
// most majors will require some manual effort to upgrade to, so we don't want to create
// PRs automatically or else we'll just spam ourselves.
dependencyDashboardApproval: true,
},
// by default renovate will auto-rebase whenever the dep pranch falls behind main.
// this is annoying as it spams notifications and creates unnecessary action runs.
// instead only auto-rebase when conflicted, and we can trigger a manual rebase if required.
rebaseWhen: "conflicted",
stabilityDays: 3,
}
19 changes: 19 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Node.js CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
ci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 'lts/*'
- run: npm ci

- run: npm run format:check
- run: npm run lint
- run: npm run test
24 changes: 0 additions & 24 deletions .github/workflows/node.js.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Node.js 16.x
uses: actions/setup-node@v3
Expand Down
4 changes: 1 addition & 3 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@
"default": {
"runner": "nx/tasks-runners/default",
"options": {
"cacheableOperations": [
"test"
]
"cacheableOperations": ["test"]
}
}
},
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"test": "npm run test -ws",
"prepare": "husky install",
"format": "prettier --write \"**/*.{js,css,md}\"",
"format:check": "prettier --check \"**/*.{js,css,md}\"",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
"version": "changeset version",
Expand Down
2 changes: 1 addition & 1 deletion packages/mono-1/src/mod.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ import { strict as assert } from "node:assert";
import { answer } from "./mod";

test("mono-2", function () {
assert.equal(answer, 42);
assert.equal(answer, 42);
});
2 changes: 1 addition & 1 deletion packages/mono-2/src/mod.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ import { strict as assert } from "node:assert";
import { answer } from "./mod";

test("mono-2", function () {
assert.equal(answer, 42);
assert.equal(answer, 42);
});

0 comments on commit a91d311

Please sign in to comment.