Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions ember-primitives/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"bin": "./bin/index.mjs",
"scripts": {
"build": "rollup --config ./rollup.config.mjs",
"sync": "echo 'pnpm is syncing this package into the workspaces that inject it. (this is configured in .npmrc)'",
"lint": "concurrently 'pnpm:lint:*(!fix)' --names 'lint:'",
"lint:fix": "concurrently 'pnpm:lint:*:fix' --names 'fix:' && pnpm format",
"lint:js": "eslint . --cache",
Expand Down
31 changes: 21 additions & 10 deletions turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@
/////////////////////////////////////////////////
/////////////////////////////////////////////////
"dev": {
"dependsOn": ["^build"],
"dependsOn": ["^build", "^sync"],
"cache": false,
"persistent": true
},
"start": {
"dependsOn": ["^build"],
"dependsOn": ["^build", "^sync"],
"outputs": [],
"cache": false,
"persistent": true
Expand All @@ -68,7 +68,7 @@
// development
"build:dev": {
"outputs": ["dist/**", "dist-types/**", "declarations/**"],
"dependsOn": ["^build"]
"dependsOn": ["^build", "^sync"]
},
"pack": {
"outputs": ["*.tgz"],
Expand All @@ -77,23 +77,34 @@
// production
"build": {
"outputs": ["dist/**", "dist-types/**", "declarations/**", "docs.json"],
"dependsOn": ["^build", "//#sync"]
"dependsOn": ["^build", "^sync"]
},
// Injected workspace deps (see dependenciesMeta) are hardlinked copies,
// so a dependent's node_modules does not see its dependency's `dist/`
// until pnpm re-syncs. `.npmrc`'s sync-injected-deps-after-scripts makes
// pnpm do that after the `build` *and* `sync` scripts -- but on a turbo
// cache hit the `build` script never runs, so nothing syncs and the
// dependent resolves a package with no `dist/`. Hence this task: it is
// uncached, so it always runs, and it depends on the (possibly restored)
// `build`, so it always has something to copy.
"sync": {
"dependsOn": ["build"],
"cache": false
},
"//#sync": {},
"test": {
"outputs": [],
"dependsOn": ["^build"]
"dependsOn": ["^build", "^sync"]
},
// Apps will have test:ember and test:browserstack
// They are separate so that they can cache independently
// and provide more variability than just "test"
"test:ember": {
"env": ["CI_BROWSER", "EMBER_TRY_CURRENT_SCENARIO", "EMBROIDER_TEST_SETUP_OPTIONS"],
"dependsOn": ["^build"]
"dependsOn": ["^build", "^sync"]
},
// All scenarios
"test:scenarios": {
"dependsOn": ["^build"]
"dependsOn": ["^build", "^sync"]
},

/////////////////////////////////////////////////
Expand All @@ -114,10 +125,10 @@
"lint:published-types"
]
},
"lint:js": { "outputs": [], "dependsOn": ["^build"] },
"lint:js": { "outputs": [], "dependsOn": ["^build", "^sync"] },
"lint:hbs": { "outputs": [] },
"lint:prettier": { "outputs": [] },
"lint:types": { "outputs": [], "dependsOn": ["^build"] },
"lint:types": { "outputs": [], "dependsOn": ["^build", "^sync"] },
"lint:package": { "outputs": [], "dependsOn": ["build"] },
"lint:published-types": { "outputs": [], "dependsOn": ["pack"] },

Expand Down
Loading