mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
Patch the makefile to automaticaly create the output dir if it doesn't exists, use PWD to work in different computer base_dir from scratch
This commit is contained in:
parent
acb65b77af
commit
66ca61dfbb
1 changed files with 5 additions and 4 deletions
|
|
@ -9,7 +9,7 @@ TEMPLATES={
|
|||
PELICAN=$pelican
|
||||
PELICANOPTS=$pelicanopts
|
||||
|
||||
BASEDIR=$basedir
|
||||
BASEDIR=$$(PWD)
|
||||
INPUTDIR=$$(BASEDIR)/src
|
||||
OUTPUTDIR=$$(BASEDIR)/output
|
||||
CONFFILE=$$(BASEDIR)/pelican.conf.py
|
||||
|
|
@ -36,20 +36,21 @@ help:
|
|||
\t@echo ' '
|
||||
|
||||
|
||||
html: $$(OUTPUTDIR)/index.html
|
||||
html: clean $$(OUTPUTDIR)/index.html
|
||||
\t@echo 'Done'
|
||||
|
||||
$$(OUTPUTDIR)/%.html:
|
||||
\t$$(PELICAN) $$(INPUTDIR) -o $$(OUTPUTDIR) -s $$(CONFFILE)
|
||||
|
||||
clean:
|
||||
\trm -r $$(OUTPUTDIR)/*
|
||||
\trm -fr $$(OUTPUTDIR)
|
||||
\tmkdir $$(OUTPUTDIR)
|
||||
|
||||
dropbox_upload: $$(OUTPUTDIR)/index.html
|
||||
\tcp -r $$(OUTPUTDIR)/* $$(DROPBOX_DIR)
|
||||
|
||||
ssh_upload: $$(OUTPUTDIR)/index.html
|
||||
\tscp -rv $$(OUTPUTDIR)/* $$(SSH_USER)@$$(SSH_HOST)/$$(SSH_TARGET_DIR)
|
||||
\tscp -r $$(OUTPUTDIR)/* $$(SSH_USER)@$$(SSH_HOST):$$(SSH_TARGET_DIR)
|
||||
|
||||
ftp_upload: $$(OUTPUTDIR)/index.html
|
||||
\tlftp ftp://$$(FTP_USER)@$$(FTP_HOST) -e "mirror -R $$(OUTPUT_DIR)/* $$(FTP_TARGET_DIR) ; quit"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue