fixing actions

This commit is contained in:
Ace 2023-06-03 19:03:09 +02:00
parent 436d3acecd
commit deedc7a0f5

View File

@ -4,7 +4,7 @@ on:
push: push:
branches: branches:
- main - main
jobs: jobs:
build: build:
name: run Inkycal tests name: run Inkycal tests
@ -13,40 +13,40 @@ jobs:
contents: write contents: write
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- name: Set up Python 3.9 - name: Set up Python 3.9
uses: actions/setup-python@v4 uses: actions/setup-python@v4
with: with:
python-version: 3.9 python-version: 3.9
- name: Clone repo - name: Clone repo
run: | run: |
git clone https://github.com/aceinnolab/Inkycal git clone https://github.com/aceinnolab/Inkycal
- name: Generate docs and run tests - name: Generate docs and run tests
env: env:
OPENWEATHERMAP_API_KEY: ${{ secrets.OPENWEATHERMAP_API_KEY }} OPENWEATHERMAP_API_KEY: ${{ secrets.OPENWEATHERMAP_API_KEY }}
SAMPLE_ICAL_URL: ${{ secrets.SAMPLE_ICAL_URL }} SAMPLE_ICAL_URL: ${{ secrets.SAMPLE_ICAL_URL }}
TEST_ICAL_URL: ${{ secrets.TEST_ICAL_URL }} TEST_ICAL_URL: ${{ secrets.TEST_ICAL_URL }}
TODOIST_API_KEY: ${{ secrets.TODOIST_API_KEY }} TODOIST_API_KEY: ${{ secrets.TODOIST_API_KEY }}
run: | run: |
cd Inkycal cd Inkycal
echo "$PWD" echo "$PWD"
python3 -m venv venv python3 -m venv venv
source venv/bin/activate source venv/bin/activate
python -m pip install --upgrade pip python -m pip install --upgrade pip
pip install wheel pip install wheel
pip install -e ./ pip install -e ./
cd docsource && make html cd docsource && make html
make github make github
cd .. cd ..
# cd inkycal/tests # cd inkycal/tests
# wget https://raw.githubusercontent.com/aceinnolab/Inkycal/assets/tests/settings.json # wget https://raw.githubusercontent.com/aceinnolab/Inkycal/assets/tests/settings.json
# for f in *.py; do python3 "$f"; done # for f in *.py; do python3 "$f"; done
# cd .. && cd .. # cd .. && cd ..
git config --global user.name 'GitHub Actions' git config --global user.name 'GitHub Actions'
git config --global user.email 'actions@github.com' git config --global user.email 'actions@github.com'
git add docs git add docs
git commit -m "Update documentation" git commit -m "Update documentation"
git push --force --quiet git push --force --quiet