3 Commits

Author SHA1 Message Date
Stephan
030cc2b97d wip 2021-06-04 11:50:43 +02:00
Stephan
178d291e4d wip 2021-06-04 11:50:34 +02:00
Stephan
8e58b6290c wip 2021-06-04 11:50:15 +02:00
2 changed files with 32 additions and 26 deletions

View File

@@ -1,20 +0,0 @@
name: Utils
description: |
Utils...
author: ZpqrtBnk <sgay@pilotine.com>
inputs:
mode:
description: Some Description
default: miss
runs:
using: composite
steps:
- shell: bash
run: echo "Hello from Utils + ${{ inputs.mode }}"
branding:
color: blue
icon: file-text

View File

@@ -10,15 +10,41 @@ jobs:
runs-on: ubuntu-latest
steps:
#- name: Experiment
# uses: zpqrtbnk/gh-actions/experiment@master
- name: Experiment
uses: zpqrtbnk/gh-actions/experiment@master
- name: Infos
shell: bash
run: |
echo "github.ref: '${{ github.ref }}'"
echo "github.sha: '${{ github.sha }}'"
- name: Checkout
uses: actions/checkout@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Invoke
uses: ./.github/actions/utils
with:
mode: meh
- name: Report
shell: bash
run: |
git log --graph --pretty=format':%h%%d %s %an, %ar' | head -n 5
if [ "${{ github.ref }}#refs/heads/" != "${{ github.ref }}" ]; then
# a commit, not a tag
echo "COMMIT"
BRANCH="${{ github.ref }}#refs/heads/"
git fetch origin wip-$BRANCH:wip-$BRANCH
if [ $? -ne 0 ]; then
echo "TAG NOT FOUND"
else
TAGSHA=$(git rev-parse wip-$BRANCH)
echo "FOUND TAG $TAGSHA"
if [ "$TAGSHA" != "${{ github.sha }}" ]; then
echo "BAD TAG"
else
echo "GOOD TAG"
fi
fi
else
# a tag?
echo "TAG"
fi