mirror of
https://github.com/dnote/dnote
synced 2026-03-14 22:45:50 +01:00
Allow to build assets without watching
This commit is contained in:
parent
8c13525177
commit
9cf33a9632
5 changed files with 11 additions and 4 deletions
|
|
@ -10,6 +10,8 @@ inputDir="$dir/src"
|
|||
|
||||
task="cp $inputDir/main.js $outputDir"
|
||||
|
||||
|
||||
if [[ "$1" == "true" ]]; then
|
||||
(
|
||||
cd "$basePath/watcher" && \
|
||||
go run main.go \
|
||||
|
|
@ -17,3 +19,6 @@ task="cp $inputDir/main.js $outputDir"
|
|||
--context="$inputDir" \
|
||||
"$inputDir"
|
||||
)
|
||||
else
|
||||
eval "$task"
|
||||
fi
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ inputDir="$dir/src"
|
|||
|
||||
rm -rf "${outputDir:?}/*"
|
||||
|
||||
sass --version
|
||||
|
||||
task="sass \
|
||||
--style compressed \
|
||||
--source-map \
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
|
@ -18,7 +18,7 @@ mkdir -p "$basePath/pkg/server/static"
|
|||
cp "$basePath"/pkg/server/assets/static/* "$basePath/pkg/server/static"
|
||||
# run asset pipeline in the background
|
||||
(cd "$basePath/pkg/server/assets/" && "$basePath/pkg/server/assets/styles/build.sh" true ) &
|
||||
(cd "$basePath/pkg/server/assets/" && "$basePath/pkg/server/assets/js/build.sh") &
|
||||
(cd "$basePath/pkg/server/assets/" && "$basePath/pkg/server/assets/js/build.sh" true ) &
|
||||
|
||||
# run server
|
||||
moduleName="github.com/dnote/dnote"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue