-
Notifications
You must be signed in to change notification settings - Fork 4
Improvement in cleaning mock releases #135
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
wojciech-piotrowiak
wants to merge
27
commits into
develop
Choose a base branch
from
fix-in-mock-cleanup
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
182782a
workflow logs
wojciech-piotrowiak c32ec10
disabling activiti-cloud-full-chart
wojciech-piotrowiak d2df342
enabling activiti-cloud-full-chart
wojciech-piotrowiak f6daf57
different log message+catching problems with removal
wojciech-piotrowiak f7f1302
different log message+catching problems with removal
wojciech-piotrowiak 9786b74
no depth
wojciech-piotrowiak a4f129d
cd
wojciech-piotrowiak d586366
bot added
wojciech-piotrowiak 42f6d44
different approach
wojciech-piotrowiak 5475d5e
refactor
wojciech-piotrowiak 16ee16b
refactor
wojciech-piotrowiak e6c9da6
format
wojciech-piotrowiak d89334f
typo
wojciech-piotrowiak 052a841
fix
wojciech-piotrowiak e5b77fe
fix
wojciech-piotrowiak 9e5333b
fix
wojciech-piotrowiak 32909ef
fix
wojciech-piotrowiak bbc20ac
post checkout
wojciech-piotrowiak cc36d46
refactor
wojciech-piotrowiak 3e95a3b
better logs+pinning
wojciech-piotrowiak e2ade1d
fail safe to false, reorder
wojciech-piotrowiak 3d357f7
extra check
wojciech-piotrowiak 0f0c076
repo activiti-scripts added to matrix responsible for creating gh rel…
wojciech-piotrowiak 99b075a
Apply suggestions from code review
wojciech-piotrowiak 51122cb
logs fix
wojciech-piotrowiak 2d4aeec
Update .github/actions/remove-mock-release-and-tag/action.yml
wojciech-piotrowiak 6cba7ef
double echo removed
wojciech-piotrowiak File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,55 @@ | ||
| name: Mock release cleanup | ||
| description: Remove mock release and tag on a repository | ||
| inputs: | ||
| version: | ||
| description: Mock release version to be removed from tags and releases (should end with -mock) | ||
| required: true | ||
| repo: | ||
| description: Path the repository | ||
| required: true | ||
| gh-token: | ||
| description: 'GitHub Token' | ||
| required: true | ||
| runs: | ||
| using: composite | ||
| steps: | ||
| - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1 | ||
| with: | ||
| repository: ${{ inputs.repo }} | ||
| token: ${{ inputs.gh-token }} | ||
|
|
||
| - uses: Alfresco/alfresco-build-tools/.github/actions/git-check-existing-tag@34b2301fc6245fa98ed73a82e04d4f9ab4eb5a3f #v3.6.0 | ||
| id: check-tag | ||
| with: | ||
| tag: ${{ inputs.version }} | ||
|
|
||
| - name: Delete tag if it exist and ends with "-mock" | ||
| if: steps.check-tag.outputs.exists == 'true' | ||
| shell: bash | ||
| env: | ||
| GITHUB_TOKEN: ${{ inputs.gh-token }} | ||
| VERSION: ${{ inputs.version }} | ||
| run: | | ||
| if [[ "${VERSION}" == *-mock ]]; then | ||
wojciech-piotrowiak marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| echo "Removing '${VERSION}' tag from: ${REPO}" | ||
| git push origin --delete ${VERSION} || true | ||
| else | ||
| echo "Error: The provided version does not end with '-mock.'" | ||
| exit 1 | ||
| fi | ||
|
|
||
| - name: Delete release if the provided version ends with "-mock" | ||
| id: delete_version | ||
| shell: bash | ||
| env: | ||
| GITHUB_TOKEN: ${{ inputs.gh-token }} | ||
| VERSION: ${{ inputs.version }} | ||
| REPO: ${{ inputs.repo }} | ||
| run: | | ||
| if [[ "${VERSION}" == *-mock ]]; then | ||
| echo "Removing '${VERSION}' release from: ${REPO}" | ||
| gh release delete -R ${REPO} -y ${VERSION} | ||
| else | ||
| echo "Error: The provided version does not end with '-mock.'" | ||
| exit 1 | ||
| fi | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.