Skip to content

Commit 6cf23ae

Browse files
committed
build the icons when needed
It seems the prepare script has some issues and we can't always depend on it for donig the right thing. We'll just run the build script when needed.
1 parent 21851f3 commit 6cf23ae

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

.github/workflows/ci.yml

+6
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ jobs:
2626
cache: npm
2727
- name: Install Dependencies
2828
run: npm ci
29+
- name: Build icons
30+
run: npm run build:icons
2931
- name: Lint
3032
run: npm run lint
3133
- name: Run Tests
@@ -44,6 +46,8 @@ jobs:
4446
cache: npm
4547
- name: Install Dependencies
4648
run: npm install --no-shrinkwrap
49+
- name: Build icons
50+
run: npm run build:icons
4751
- name: Run Tests
4852
run: npm run test:ember
4953

@@ -73,5 +77,7 @@ jobs:
7377
cache: npm
7478
- name: Install Dependencies
7579
run: npm ci
80+
- name: Build icons
81+
run: npm run build:icons
7682
- name: Run Tests
7783
run: ./node_modules/.bin/ember try:one ${{ matrix.try-scenario }}

package.json

+6-8
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
"test": "tests"
3333
},
3434
"scripts": {
35-
"build": "run-s icons build-ember build-storybook",
36-
"build:icons": "node lib/generate-icon-components.mjs",
35+
"build": "run-s build-ember build-storybook",
36+
"build:icons": "concurrently \"node lib/generate-icon-components.mjs\" \"svg-symbols ./public/icons > ./public/appuniversum-symbolset.svg\"",
3737
"build:types": "glint -d",
3838
"lint": "concurrently \"npm:lint:*(!fix)\" --names \"lint:\"",
3939
"lint:css": "stylelint --allow-empty-input \"**/*.css\"",
@@ -46,20 +46,18 @@
4646
"lint:js": "eslint . --cache",
4747
"lint:js:fix": "eslint . --fix",
4848
"lint:types": "glint",
49-
"prepack": "glint -d",
49+
"prepack": "run-s build:icons build:types",
5050
"postpack": "rimraf declarations",
5151
"start": "run-p ember storybook",
52-
"ember": "ember serve",
52+
"ember": "npm run build:icons && ember serve",
5353
"test": "concurrently \"npm:lint\" \"npm:test:*\" --names \"lint,test:\"",
5454
"test:ember": "ember test",
5555
"test:ember-compatibility": "ember try:each",
56-
"icons": "svg-symbols ./public/icons > ./public/appuniversum-symbolset.svg",
57-
"prepare": "concurrently npm:build:icons npm:icons",
5856
"storybook": "start-storybook -p 6006",
5957
"build-storybook": "build-storybook",
60-
"build-ember": "ember build --environment=production",
58+
"build-ember": "npm run build:icons && ember build --environment=production",
6159
"build-ember-chromatic": "ember build --environment=chromatic",
62-
"prep-chromatic": "run-s icons build-ember-chromatic",
60+
"prep-chromatic": "run-s build:icons build-ember-chromatic",
6361
"release": "release-it",
6462
"chromatic": "chromatic --exit-zero-on-changes"
6563
},

0 commit comments

Comments
 (0)