Skip to content

Commit

Permalink
Update commons-update.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
athulvis authored Dec 10, 2023
1 parent 8eca9b1 commit 0e72f5b
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/commons-update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ permissions: read-all

env:
PYWIKIBOT_TEST_RUNNING: 1
PYWIKIBOT_USERNAME: Athulvis@keralacovidvaccineUpdater
PYWIKIBOT_USERNAME: Athulvis
PYWIKIBOT_BOTNAME: keralacovidvaccineUpdater
PYWIKIBOT_LOGIN_LOGOUT: 1

jobs:
Expand Down Expand Up @@ -39,21 +40,23 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install python3-dotenv
pip install -r requirements.txt
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Generate user files
run: |
pwb generate_user_files -site:${{matrix.site}} -user:${{ env.PYWIKIBOT_USERNAME }} -v -debug;
echo "family = 'commons'" >> user-config.py
echo "mylang = 'commons'" >> user-config.py
echo "usernames['commons']['commons'] = '${{ env.PYWIKIBOT_USERNAME }}'" >> user-config.py
echo "password_file = 'user-password.py'" >> user-config.py
echo "max_retries = 3" >> user-config.py
echo "noisysleep = float('inf')" >> user-config.py
echo "maximum_GET_length = 5000" >> user-config.py
echo "console_encoding = 'utf8'" >> user-config.py
echo "import os" >> user-config.py
echo "password_file = os.path.expanduser('passwordfile')" >> user-config.py
echo "('${{ env.PYWIKIBOT_USERNAME }}', '${{ secrets.PWD }}')" > passwordfile
echo "('${{ env.PYWIKIBOT_USERNAME }}', BotPassword('${{ env.PYWIKIBOT_BOTNAME }}','${{ secrets.PWD }}'))" > user-password.py
- name: Update Commons
timeout-minutes: 10
Expand Down

0 comments on commit 0e72f5b

Please sign in to comment.