Skip to content

Commit

Permalink
Updates frontend-building related Makefile rules to also create
Browse files Browse the repository at this point in the history
the dist/icons.css file.
Updates the core/src/icons.js script to allow it to run before
'npm run dev', 'npm run build', or 'npm run watch' is run.

Signed-off-by: Cyrille Bollu <cyrpub@bollu.be>
  • Loading branch information
StCyr committed Jun 13, 2022
1 parent b7bce42 commit f9c874e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,18 @@ npm-update:
npm update

# Building
build-js:
build-js: build-css
npm run dev

build-js-production:
npm run build

watch-js:
npm run watch
watch-js: build-css
npm run watch &
npm run sass:watch

build-css:
npm run sass:icons

# Linting
lint-fix:
Expand Down
1 change: 1 addition & 0 deletions core/src/icons.js
Original file line number Diff line number Diff line change
Expand Up @@ -332,4 +332,5 @@ css += generateVariablesAliases(true)
css += '}'

// WRITE CSS
fs.mkdir('dist', (err) => { return })
fs.writeFileSync(path.join(__dirname, '../../dist', 'icons.css'), sass.compileString(css).css)

0 comments on commit f9c874e

Please sign in to comment.