Update git/action.yaml
This commit is contained in:
parent
6b490c2058
commit
b65199a416
11
git/action.yaml
Normal file
11
git/action.yaml
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
name: Git Checkout
|
||||||
|
desciption: Checkout repository using alpite/git
|
||||||
|
|
||||||
|
runs:
|
||||||
|
using: composite
|
||||||
|
steps:
|
||||||
|
- run: echo "URL=$(echo ${{github.server_url}} | sed s%://%://${{github.token}}@% )/${{github.repository}}.git" >> $GITHUB_ENV
|
||||||
|
- uses: docker://gitlab/gitlab-runner:alpine
|
||||||
|
with:
|
||||||
|
entrypoint: git
|
||||||
|
args: clone -b "${{github.ref_name}}" "${{env.URL}}" .
|
@ -1,16 +0,0 @@
|
|||||||
name: Git Checkout
|
|
||||||
desciption: Checkout repository using alpite/git
|
|
||||||
|
|
||||||
runs:
|
|
||||||
using: composite
|
|
||||||
steps:
|
|
||||||
- name: Checkout repository
|
|
||||||
container: git
|
|
||||||
options: -v ".:/app"
|
|
||||||
run: |
|
|
||||||
mkdir -p /app && cd /app
|
|
||||||
mkdir -p /tmp/workspace && mv * /tmp/workspace/ || echo Nothing to copy
|
|
||||||
HOST=$(echo "${{ github.server_url }}" | sed 's%https://%%')
|
|
||||||
git clone -b "${{ github.ref_name }}" "https://${{ github.token }}@$HOST/${{ github.repository }}.git" .
|
|
||||||
mv -n /tmp/workspace/* . && rm -rf /tmp/workspace
|
|
||||||
git status && echo "" && ls
|
|
Loading…
Reference in New Issue
Block a user