#2146 #914
Workflow file for this run
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: Count Action Executions | |
on: | |
push: | |
branches-ignore: | |
- main | |
jobs: | |
count_executions: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.x' # Choose the Python version you want to use | |
- name: Check if build.py needs update | |
id: check_changes | |
run: | | |
changes=$(git diff --name-only) | |
if [[ "$changes" == *"__version__.py"* ]]; then | |
echo "::set-output name=changes::0" | |
else | |
echo "::set-output name=changes::1" | |
fi | |
- name: Update build.py | |
if: steps.check_changes.outputs.changes != 0 | |
run: | | |
OPTERYX_VERSION=$(python $GITHUB_WORKSPACE/build_counter.py) | |
git config --global user.name "XB500" | |
git config --global user.email "[email protected]" | |
git add $GITHUB_WORKSPACE/opteryx/__version__.py | |
git commit -m "Opteryx Version ${OPTERYX_VERSION}" | |
git push |