refactor: moving the generated files to make it easier to include
This commit is contained in:
parent
d93ff04688
commit
aed76b4804
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -1,7 +1,7 @@
|
||||||
*.tgz
|
*.tgz
|
||||||
|
/*.css
|
||||||
|
|
||||||
.direnv/
|
.direnv/
|
||||||
dist/
|
|
||||||
node_modules/
|
node_modules/
|
||||||
|
|
||||||
# nixago: ignore-linked-files
|
# nixago: ignore-linked-files
|
||||||
|
|
5
Justfile
5
Justfile
|
@ -8,7 +8,7 @@ format:
|
||||||
prettier src/*.mjs src/*.postcss --write
|
prettier src/*.mjs src/*.postcss --write
|
||||||
|
|
||||||
format-dist:
|
format-dist:
|
||||||
prettier dist/*.css --write
|
prettier ./*.css --write
|
||||||
|
|
||||||
# Generate all the files
|
# Generate all the files
|
||||||
build: colors theme
|
build: colors theme
|
||||||
|
@ -19,5 +19,4 @@ colors: format && format-dist
|
||||||
|
|
||||||
# Generate dist/theme.css
|
# Generate dist/theme.css
|
||||||
theme: format && format-dist
|
theme: format && format-dist
|
||||||
mkdir -p dist
|
postcss src/theme.postcss > ./theme.css
|
||||||
postcss src/theme.postcss > dist/theme.css
|
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
@import url("../dist/colors.css");
|
@import url("../colors.css");
|
||||||
@import url("../dist/theme.css");
|
@import url("../theme.css");
|
||||||
|
|
|
@ -5,7 +5,7 @@ import fs from "node:fs/promises";
|
||||||
|
|
||||||
// Figure out where we need to write the files.
|
// Figure out where we need to write the files.
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||||
const distPath = __dirname + "/../dist";
|
const distPath = __dirname + "/..";
|
||||||
|
|
||||||
console.log("writing", distPath);
|
console.log("writing", distPath);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue