Skip to content

Commit

Permalink
cleanup and documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
hanstrompert committed Jan 25, 2024
1 parent 0ce310a commit b6bb04c
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions .github/workflows/tag-remote-repository.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,18 @@
#
# Use the GitHub API to tag the main branch of another repository.
#
name: Tag remote repository

on:
push:
tags:
- "@orchestrator-ui/orchestrator-ui-components@[0-9]+.[0-9]+.[0-9]+"

# The main branch of the following repository will be tagged.
# The main branch of the following repository (owner/repo) will be tagged
# with the version part (e.g. 0.3.1) of the tag trigger above.
env:
REPOSITORY_OWNER: "hanstrompert"
REPOSITORY_NAME: "test-client"
OWNER: "hanstrompert"
REPO: "test-client"

jobs:
docker:
Expand All @@ -20,9 +24,6 @@ jobs:
- name: Get latest commit SHA
id: sha
uses: actions/github-script@v7
env:
OWNER: ${{ env.REPOSITORY_OWNER }}
REPO: ${{ env.REPOSITORY_NAME }}
with:
result-encoding: string
script: |
Expand All @@ -40,16 +41,14 @@ jobs:
- name: Add tag to repository
uses: actions/github-script@v7
env:
# OWNER: ${{ env.REPOSITORY_OWNER }}
# REPO: ${{ env.REPOSITORY_NAME }}
REF: ${{ format('refs/tags/{0}', env.REF) }}
SHA: ${{ steps.sha.outputs.result }}
with:
github-token: ${{ secrets.TOKEN_CREATE_TAG_TEST_CLIENT }}
script: |
await github.rest.git.createRef({
owner: process.env.REPOSITORY_OWNER,
repo: process.env.REPOSITORY_NAME,
owner: process.env.OWNER,
repo: process.env.REPO,
ref: process.env.REF,
sha: process.env.SHA,
})

0 comments on commit b6bb04c

Please sign in to comment.