moving the deploy scripts arround

This commit is contained in:
Chris McKenzie
2023-09-06 18:09:14 -07:00
parent ab9606d6df
commit a74f8e93b6
4 changed files with 80 additions and 0 deletions

40
deploy/v4.sh Executable file
View File

@@ -0,0 +1,40 @@
#!/bin/bash
make_build() {
# we're going to make this stuff we keep out of the repo
build=build
rm -r $build
mkdir -p $build/{css,fonts,js}
./update-icons.sh $build/fonts
for what in fonts css js; do
cp -puv v4.4.1/dist/$what/* $build/$what
done
[[ -e bootstra.386-latest-v4.zip ]] && rm bootstra.386-latest-v4.zip
zip -r bootstra.386-latest-v4.zip $build
}
deploy_site(){
# I need to like inline sed some crap
# ug why ... ... ug! Also zsh does better replacers
cp -v v4.4.1/site/docs/4.4/demo.html site/
mkdir -p site/{css,fonts,js}
for what in fonts css js; do
cp -puv v4.4.1/dist/$what/* site/$what
done
# Let's hope this doesn't break the planet ... all I need
# to do is make this shit local.
sed -Ei s'/\/docs\/4.4\/dist\/(css|js)/\1/g' site/demo.html
cd site
git commit -am "updates"
git push origin HEAD
}
todo=${1:-make_build deploy_site}
for i in $todo; do
eval $i
done

40
deploy/v5.sh Executable file
View File

@@ -0,0 +1,40 @@
#!/bin/bash
make_build() {
# we're going to make this stuff we keep out of the repo
build=build
rm -r $build
mkdir -p $build/{css,fonts,js}
./update-icons.sh $build/fonts
for what in fonts css js; do
cp -puv v4.4.1/dist/$what/* $build/$what
done
[[ -e bootstra.386-latest-v4.zip ]] && rm bootstra.386-latest-v4.zip
zip -r bootstra.386-latest-v4.zip $build
}
deploy_site(){
# I need to like inline sed some crap
# ug why ... ... ug! Also zsh does better replacers
cp -v v4.4.1/site/docs/4.4/demo.html site/
mkdir -p site/{css,fonts,js}
for what in fonts css js; do
cp -puv v4.4.1/dist/$what/* site/$what
done
# Let's hope this doesn't break the planet ... all I need
# to do is make this shit local.
sed -Ei s'/\/docs\/4.4\/dist\/(css|js)/\1/g' site/demo.html
cd site
git commit -am "updates"
git push origin HEAD
}
todo=${1:-make_build deploy_site}
for i in $todo; do
eval $i
done