Skip to content

fix(CI): syntax

fix(CI): syntax #24

Workflow file for this run

name: Mirror Workflow 🪞
env:
SOURCE_REPO: "EdukaiFR/website"
MIRROR_URL: "khalidbelk/testCI.git"
on:
push:
branches:
- main
- feat/CI
- testCI
jobs:
push_to_mirror:
if: github.repository == ${{ env.SOURCE_REPO }}

Check failure on line 16 in .github/workflows/mirrorV2.yml

View workflow run for this annotation

GitHub Actions / Mirror Workflow 🪞

Invalid workflow file

The workflow is not valid. .github/workflows/mirrorV2.yml (Line: 16, Col: 9): Unrecognized named-value: 'env'. Located at position 1 within expression: env.SOURCE_REPO
runs-on: ubuntu-latest
steps:
- name: Checkout source
uses: actions/checkout@v3
with:
fetch-depth: 0
ref: feat/CI
token: ${{ secrets.PAT_TOKEN }}
- name: Push to mirror
run: |
set -e
git config user.name "Github Action"
git config user.email "action@github.com"
git remote add mirror https://${PAT}@github.com/${{ env.MIRROR_URL }}
git commit --allow-empty -m "[Mirror CI] - Update repository"
git push mirror feat/CI:testCI --force