diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b40e8a7..6f196a5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,8 +2,6 @@ name: Build on: push: pull_request: - delete: - workflow_dispatch: jobs: build: @@ -11,15 +9,18 @@ jobs: strategy: fail-fast: false matrix: - os: [ macos-latest, windows-latest, ubuntu-24.04 ] + os: [ macOS,Windows,ubuntu-24.04] runs-on: ${{ matrix.os }} steps: - name: Checkout uses: actions/checkout@v4 + with: + fetch-depth: 0 + lfs: true + - name: Build uses: 4d/build4d-action@main with: - ignore-warnings: true product-line: vcs version: vcs build: official @@ -33,8 +34,19 @@ jobs: with: fetch-depth: 0 lfs: true - - uses: wangchucheng/git-repo-sync@v0.1.0 + + - name: Get Internal Sync action + uses: actions/checkout@v4 + with: + repository: 4d/gitlabsync-action + ref: main + path: .github/workflows/external/sync + token: ${{ secrets.CI_GIT_SYNC }} + + - id: Sync + uses: ./.github/workflows/external/sync/ with: target-url: ${{ secrets.TARGET_URL }} target-username: ${{ secrets.TARGET_USERNAME }} target-token: ${{ secrets.TARGET_TOKEN }} + diff --git a/.github/workflows/sync_on_deleted.yml b/.github/workflows/sync_on_deleted.yml new file mode 100644 index 0000000..f2de386 --- /dev/null +++ b/.github/workflows/sync_on_deleted.yml @@ -0,0 +1,30 @@ +name: Delete + +on: + delete + +jobs: + sync: + runs-on: [self-hosted, macOS, ARM64] + name: Git Repo Sync + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + lfs: true + + - name: Get Internal Sync action + uses: actions/checkout@v4 + with: + repository: 4d/gitlabsync-action + ref: main + path: .github/workflows/external/sync + token: ${{ secrets.CI_GIT_SYNC }} + + - id: Sync + uses: ./.github/workflows/external/sync/ + with: + target-url: ${{ secrets.TARGET_URL }} + target-username: ${{ secrets.TARGET_USERNAME }} + target-token: ${{ secrets.TARGET_TOKEN }} +