Skip to content

Commit b4e2ced

Browse files
committed
[feature] Added make html SKIP_YARN=1
1 parent 2a843d3 commit b4e2ced

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ ifneq ($(PORT), 0)
2626
PELICANOPTS += -p $(PORT)
2727
endif
2828

29+
SKIP_YARN ?= 0
30+
2931

3032
help:
3133
@echo 'Makefile for a pelican Web site '
@@ -41,10 +43,13 @@ help:
4143
@echo ' '
4244
@echo 'Set the DEBUG variable to 1 to enable debugging, e.g. make DEBUG=1 html '
4345
@echo 'Set the RELATIVE variable to 1 to enable relative urls '
46+
@echo 'Set the SKIP_YARN variable to 1 to skip yarn build, e.g. make SKIP_YARN=1 html'
4447
@echo ' '
4548

4649
html:
50+
ifeq ($(SKIP_YARN), 0)
4751
yarn build
52+
endif
4853
"$(PELICAN)" "$(INPUTDIR)" -o "$(OUTPUTDIR)" -s "$(CONFFILE)" $(PELICANOPTS)
4954
$(MAKE) post_build_cleanup
5055

README.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ Build:
2525

2626
make html
2727

28+
# if you are working only on content and
29+
# do not need to rebuild CSS/JS files:
30+
make html SKIP_YARN=1
31+
2832
Serve:
2933

3034
::

0 commit comments

Comments
 (0)