summaryrefslogtreecommitdiff
path: root/lumebuild.sh
blob: 3f794d46778007f8be4d99c45f966aa8f778974a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash

LUME_DIR="/var/www/html/soulmining"
SRC_DIR="$LUME_DIR/src"
BUILD_DIR="site"
WEBPSH="/your/webp/convert/path"

export DENO_INSTALL="/home/$USER/.deno"
export PATH="$DENO_INSTALL/bin:$PATH"

cd "$SRC_DIR" || exit

git add . || git init && git add . || exit

git commit -m "`date`"

if [ $? -eq 0 ]; then
  $WEBPSH
  cd $LUME_DIR || exit
  deno task lume --dest=$BUILD_DIR > /dev/null 2>&1
else
  exit 1
fi