mirror of
https://github.com/FranzDiebold/github-env-vars-action.git
synced 2024-11-09 18:43:32 -05:00
17 lines
718 B
Bash
Executable file
17 lines
718 B
Bash
Executable file
#!/bin/sh -l
|
|
|
|
GITHUB_REPOSITORY_OWNER=$(echo $GITHUB_REPOSITORY | cut -d'/' -f 1)
|
|
echo "::set-env name=GITHUB_REPOSITORY_OWNER::$GITHUB_REPOSITORY_OWNER"
|
|
echo "Set GITHUB_REPOSITORY_OWNER=$GITHUB_REPOSITORY_OWNER"
|
|
|
|
GITHUB_REPOSITORY_NAME=$(echo $GITHUB_REPOSITORY | cut -d'/' -f 2)
|
|
echo "::set-env name=GITHUB_REPOSITORY_NAME::$GITHUB_REPOSITORY_NAME"
|
|
echo "Set GITHUB_REPOSITORY_NAME=$GITHUB_REPOSITORY_NAME"
|
|
|
|
GITHUB_REF_NAME=$(echo $GITHUB_REF | cut -d'/' -f 3)
|
|
echo "::set-env name=GITHUB_REF_NAME::$GITHUB_REF_NAME"
|
|
echo "Set GITHUB_REF_NAME=$GITHUB_REF_NAME"
|
|
|
|
GITHUB_SHA_SHORT=$(echo $GITHUB_SHA | cut -c1-8)
|
|
echo "::set-env name=GITHUB_SHA_SHORT::$GITHUB_SHA_SHORT"
|
|
echo "Set GITHUB_SHA_SHORT=$GITHUB_SHA_SHORT"
|