adds zola_build
This commit is contained in:
@@ -12,3 +12,13 @@ function check_zola_is_present() {
|
|||||||
|
|
||||||
# function install_zola() {}
|
# function install_zola() {}
|
||||||
|
|
||||||
|
# Build Zola project from git repo
|
||||||
|
# Requires $git_url, $path_url and $final_path to be set
|
||||||
|
function zola_build() {
|
||||||
|
tmp_dir=/tmp/zola_build-$(date "+%Y%m%d")
|
||||||
|
mkdir $tmp_dir && cd $tmp_dir
|
||||||
|
git clone $git_url source
|
||||||
|
cd source/
|
||||||
|
zola build --base-url $path_url --output-dir $final_path
|
||||||
|
rm -r $tmp_dir
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user