Projects STRLCPY maigret Commits 9a4b18bd
🤬
Revision indexing in progress... (symbol navigation in revisions will be accurate after indexed)
  • ■ ■ ■ ■ ■ ■
    .github/workflows/pyinstaller.yml
    1 1  name: Package exe with PyInstaller - Windows
    2 2   
    3 3  on:
    4  - push:
    5  - branches: [ main ]
    6  - pull_request:
    7  - branches: [ main ]
     4 + workflow_run:
     5 + workflows: [ Update sites rating and statistics ]
     6 + types:
     7 + - completed
    8 8   
    9 9  jobs:
    10 10   build:
    skipped 15 lines
  • ■ ■ ■ ■ ■ ■
    .github/workflows/python-package.yml
    1 1  name: Linting and testing
    2 2   
    3 3  on:
    4  - push:
    5  - branches: [ main ]
    6 4   pull_request:
    7 5   branches: [ main ]
    8 6   
    9 7  jobs:
    10 8   build:
    11  - 
    12 9   runs-on: ubuntu-latest
    13 10   strategy:
    14 11   matrix:
    skipped 17 lines
  • ■ ■ ■ ■ ■
    .github/workflows/update-site-data.yml
    1  -name: Update sites rating
     1 +name: Update sites rating and statistics
    2 2   
    3 3  on:
    4  - push:
    5  - branches: [ main ]
    6 4   pull_request:
    7 5   branches: [ main ]
     6 + types: [opened, synchronize]
    8 7   
    9 8  jobs:
    10 9   build:
    11 10   runs-on: ubuntu-latest
    12 11   steps:
    13  - - name: checkout repo
    14  - uses: actions/checkout@v2
     12 + - name: Checkout repository
     13 + uses: actions/checkout@v2.3.2
     14 + with:
     15 + ref: ${{ github.event.pull_request.head.sha }}
     16 + fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
     17 + 
    15 18   - name: build application
    16 19   run: |
    17 20   pip3 install .
    18 21   python3 ./utils/update_site_data.py --empty-only
    19 22   
     23 + - name: Commit and push changes
     24 + run: |
     25 + git config --global user.name "Maigret autoupdate"
     26 + git config --global user.email "[email protected]"
     27 + 
     28 + echo `git name-rev ${{ github.event.pull_request.head.sha }} --name-only`
     29 + 
     30 + export BRANCH=`git name-rev ${{ github.event.pull_request.head.sha }} --name-only | sed 's/remotes\/origin\///'`
     31 + echo $BRANCH
     32 + 
     33 + git remote -v
     34 + git checkout $BRANCH
     35 + 
     36 + git add sites.md
     37 + git commit -m "Updated site list and statistics"
     38 + 
     39 + git push origin $BRANCH
     40 + 
Please wait...
Page is in error, reload to recover