Fetch Prices #7
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: Fetch Prices | |
on: | |
schedule: | |
- cron: '0 0 * * *' | |
jobs: | |
fetch_prices: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Run daily generation | |
run: | | |
chmod +x fetch_prices.sh daily_blender.sh | |
./fetch_prices.sh > data.txt | |
cp data.txt data/"$(date +'%m-%d-%Y').txt" | |
./daily_blender.sh | |
- name: Commit changes | |
run: | | |
git config --global user.name "madjin" | |
git config --global user.email "[email protected]" | |
git add -A . | |
git commit -m "Update files" | |
- name: Push changes | |
uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
branch: main |