Aggiornamento semi-automatico 2023-09-01T12:17:03CEST
This commit is contained in:
parent
20440c2b6c
commit
22aa11b70d
|
@ -1,2 +1 @@
|
|||
make.*
|
||||
public_html/
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
@echo off
|
||||
|
||||
cd openring
|
||||
python "openring.py"
|
||||
cd ..
|
||||
zola build
|
|
@ -0,0 +1,22 @@
|
|||
#!/bin/bash
|
||||
|
||||
file="./templates/openring.html"
|
||||
if [ -e "$file" ]; then
|
||||
file_time=$(date -r "$file" +%s)
|
||||
tempo_max=$(date -d '16 hours ago' +%s)
|
||||
fi
|
||||
|
||||
if [ ! -e "$file" ] || (( $file_time < $tempo_max )); then
|
||||
cd openring
|
||||
./openring -S "feeds.txt" -n 5 < "in.html" > "../templates/openring.html"
|
||||
./openring_it -S "feeds-it.txt" -n 5 < "in_it.html" > "../templates/openringit.html"
|
||||
cd ..
|
||||
else
|
||||
echo "Feed generato troppo di recente. Operazione saltata."
|
||||
fi
|
||||
|
||||
git add --all
|
||||
git commit -S -m "Aggiornamento semi-automatico $(date +%Y-%m-%dT%H:%M:%S%Z)"
|
||||
git push -u origin master
|
||||
|
||||
zola build
|
Loading…
Reference in New Issue