fix automakefortune.sh
failed last week because i forgot dumb stuff.
This commit is contained in:
@@ -1,4 +1,6 @@
|
|||||||
#!/usr/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
cd $HOME
|
||||||
|
yes | rm -r tetosong
|
||||||
git clone git@github.com:eric5949/tetosong.git
|
git clone git@github.com:eric5949/tetosong.git
|
||||||
cd tetosong
|
cd tetosong
|
||||||
ARTIST=140308 # 116 is Kasane Teto
|
ARTIST=140308 # 116 is Kasane Teto
|
||||||
@@ -50,7 +52,7 @@ while true; do
|
|||||||
echo ""
|
echo ""
|
||||||
echo "▼・ᴗ・▼"
|
echo "▼・ᴗ・▼"
|
||||||
echo "%"
|
echo "%"
|
||||||
done >> tetofortunes
|
done >> fortunes/tetosotd/tetofortunes
|
||||||
if [ "$START" -ge "$MAX" ]; then
|
if [ "$START" -ge "$MAX" ]; then
|
||||||
echo "Reached max results. Stopping."
|
echo "Reached max results. Stopping."
|
||||||
break
|
break
|
||||||
@@ -59,7 +61,8 @@ while true; do
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
# create the fortune database from tetofortunes
|
# create the fortune database from tetofortunes
|
||||||
rm tetofortunes.dat # delete the old database if it extists.
|
rm fortunes/tetosotd/tetofortunes.dat # delete the old database if it extists.
|
||||||
strfile -c % tetofortunes tetofortunes.dat
|
strfile -c % fortunes/tetosotd/tetofortunes fortunes/tetosotd/tetofortunes.dat
|
||||||
|
git add fortunes/tetosotd/tetofortunes fortunes/tetosotd/tetofortunes.dat var.json
|
||||||
git commit -m "Update fortune files"
|
git commit -m "Update fortune files"
|
||||||
git push -u origin main
|
git push -u origin main
|
||||||
|
|||||||
Reference in New Issue
Block a user