replaced "out" with "public" as site directory

This commit is contained in:
/dev/urandom 2022-03-16 21:35:44 +03:00
parent 89b1e88f70
commit e768e64c2e
2 changed files with 6 additions and 6 deletions

View file

@ -15,12 +15,12 @@ build-job: # This job runs in the build stage, which runs first.
- make THEME=discount-theme - make THEME=discount-theme
artifacts: artifacts:
paths: paths:
- "out" - "public"
unit-test-job: # This job runs in the test stage. unit-test-job: # This job runs in the test stage.
stage: test # It only starts when the job in the build stage completes successfully. stage: test # It only starts when the job in the build stage completes successfully.
script: script:
- test $(stat -c %s out/index.html) -gt 0 #test that the index file exists - test $(stat -c %s public/index.html) -gt 0 #test that the index file exists
deploy-job: # This job runs in the deploy stage. deploy-job: # This job runs in the deploy stage.
stage: deploy # It only runs when *both* jobs in the test stage complete successfully. stage: deploy # It only runs when *both* jobs in the test stage complete successfully.
@ -36,5 +36,5 @@ deploy-job: # This job runs in the deploy stage.
- curl https://gitlab.com/dev_urandom/neocities-uploader/-/raw/main/upload.sh?inline=false > upload.sh - curl https://gitlab.com/dev_urandom/neocities-uploader/-/raw/main/upload.sh?inline=false > upload.sh
- chmod +x upload.sh - chmod +x upload.sh
script: script:
- rsync -e "ssh -o StrictHostKeyChecking=no" -ciIlprz out/ deploy@devurandom.xyz:~/out/ - rsync -e "ssh -o StrictHostKeyChecking=no" -ciIlprz public/ deploy@devurandom.xyz:~/out/
- ./upload.sh - ./upload.sh

View file

@ -1,6 +1,6 @@
-include Makefile.cfg -include Makefile.cfg
OUTDIR=out OUTDIR=public
PAGEDIR=pages PAGEDIR=pages
SRCDIR=src SRCDIR=src
TPLDIR=tpl TPLDIR=tpl
@ -30,7 +30,7 @@ DIRECTORIES = $(patsubst $(PAGEDIR)/, $(OUTDIR)/, $(_PAGES))
_STATIC_FILES = $(shell find -L static/ -type f -name \* | grep -v \\.h$) _STATIC_FILES = $(shell find -L static/ -type f -name \* | grep -v \\.h$)
_STATIC_HEADERS = $(shell find -L static/ -type f -name \*\\.h) _STATIC_HEADERS = $(shell find -L static/ -type f -name \*\\.h)
OUT_STATIC = $(patsubst static/%,out/%,$(_STATIC_FILES)) $(patsubst static/%.h,out/%,$(_STATIC_HEADERS)) OUT_STATIC = $(patsubst static/%,public/%,$(_STATIC_FILES)) $(patsubst static/%.h,public/%,$(_STATIC_HEADERS))
.SUFFIXES: .SUFFIXES:
.PHONY: all upload .PHONY: all upload
@ -92,4 +92,4 @@ $(OUTDIR)/%: static/%
cp -r $< $@ cp -r $< $@
clean: clean:
rm -rf out/* pages/blog/index.md rm -rf public/* pages/blog/index.md