Skip to content

Update main.yml

Update main.yml #5

Workflow file for this run

name: "Produce New Tag"
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Get Flutter version (Optional)
id: get_flutter_version
uses: its404/[email protected]
- name: Output Flutter version (Optional)
run: echo 'version_number:' ${{ steps.get_flutter_version.outputs.version_number }} ' build_number:' ${{ steps.get_flutter_version.outputs.build_number }}
- name: Get latest tag pushed
id: tag
uses: oprypin/[email protected]
with:
repository: ya27hw/equran_app
releases-only: true
- run: echo "${{ steps.tag.outputs.tag }}"
- name: Compare Versions and Create Tag (Modified)
if: ${{ 'v' + steps.get_flutter_version.outputs.version_number > steps.tag.outputs.tag }} # Modified Condition

Check failure on line 29 in .github/workflows/main.yml

View workflow run for this annotation

GitHub Actions / Produce New Tag

Invalid workflow file

The workflow is not valid. .github/workflows/main.yml (Line: 29, Col: 12): Unexpected symbol: '+'. Located at position 5 within expression: 'v' + steps.get_flutter_version.outputs.version_number > steps.tag.outputs.tag
run: |
VERSION=${{ steps.get_flutter_version.outputs.version_number }}
git tag -a $VERSION -m "Automatic tag for version $VERSION"
git push origin $VERSION