crea feed RSS delibere e leggi #1641
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: crea feed RSS delibere e leggi | |
on: | |
push: | |
repository_dispatch: | |
schedule: | |
- cron: '0 6 */1 * *' | |
workflow_dispatch: | |
jobs: | |
scheduled: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Utilizza l'action github checkout@v2, per automatizzare il check-out | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: crea cartella utente bin, copia dentro l'eseguibile di miller e scrape, installa xmlstarlet, gooodtables e yq | |
run: |- | |
mkdir -p ~/bin | |
cp bin/mlr ~/bin | |
cp bin/scrape ~/bin | |
cd ~/bin | |
chmod +x mlr | |
chmod +x scrape | |
sudo apt-get install xmlstarlet | |
sudo pip install yq | |
# sudo pip install goodtables | |
- name: scarica i dati e crea feed | |
env: | |
SUPER_SECRET: ${{ secrets.IFTTT }} | |
run: |- | |
export PATH=$PATH:~/bin | |
chmod +x ./delibereLeggi.sh | |
./delibereLeggi.sh | |
- name: Committa e pusha se ci sono variazioni nei dati | |
run: |- | |
git config user.name "automatico" | |
git config user.email "actions@users.noreply.github.com" | |
git add -A | |
timestamp=$(date --iso-8601=seconds) | |
git commit -m "Data e ora aggiornamento: ${timestamp}" || exit 0 | |
git push |