Skip to content

dfgdfgdfg

dfgdfgdfg #3

Workflow file for this run

name: Update Check
on:
push:
branches:
- main
jobs:
update-check:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Update Plugin Version
run: |
# Get the current plugin version
CURRENT_VERSION=$(grep -o "Version: [0-9]\+\.[0-9]\+\.[0-9]\+" interesttracker-wp-integrator-rabi.php | awk '{print $2}')
# Increment the version number (assuming semantic versioning)
NEW_VERSION=$(echo $CURRENT_VERSION | awk -F. '{print $1"."$2"."$3+1}')
# Update the plugin version in the main plugin file
sed -i "s/Version: $CURRENT_VERSION/Version: $NEW_VERSION/" interesttracker-wp-integrator-rabi.php
# Commit the changes
git add interesttracker-wp-integrator-rabi.php
git commit -m "Update plugin version to $NEW_VERSION"
git push origin main
env:
GITHUB_TOKEN: ${{ secrets.MY_SECRET_KEY }}