Skip to content

Commit

Permalink
Fixes yarn dev
Browse files Browse the repository at this point in the history
  • Loading branch information
amir20 committed Mar 23, 2021
1 parent 8980b41 commit abe9d4b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
18 changes: 10 additions & 8 deletions Makefile
Expand Up @@ -8,19 +8,21 @@ publish:

.PHONY: clean
clean:
@rm -rf static dozzle
@rm -rf static
@go clean

static: $(shell find assets -type f)
ifdef SKIP_ASSET
.PHONY: static
static:
@yarn build

.PHONY: fake_static
fake_static:
@echo 'Skipping yarn build'
@mkdir -p static
@touch static/index.html
else
yarn build
endif
@echo "yarn build was skipped" > static/index.html

.PHONY: test
test: static
test: fake_static
go test -cover ./...

build: static
Expand Down
1 change: 1 addition & 0 deletions package.json
Expand Up @@ -6,6 +6,7 @@
"watch": "npm-run-all -p watch:*",
"watch:assets": "webpack --mode=development --watch",
"watch:server": "reflex -c .reflex",
"predev": "make fake_static",
"dev": "npm-run-all -p dev-server watch:server",
"dev-server": "webpack serve --mode=development",
"prebuild": "yarn clean",
Expand Down

0 comments on commit abe9d4b

Please sign in to comment.