Skip to content

Commit c994ba6

Browse files
committed
Put push action to separate workflow.
1 parent 2a9e087 commit c994ba6

File tree

2 files changed

+20
-11
lines changed

2 files changed

+20
-11
lines changed
Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: CI
1+
name: Build and Test
22

33
on: [push]
44

@@ -23,13 +23,4 @@ jobs:
2323
pip install -r requirements.txt
2424
- name: Run Makefile test
2525
run: make test
26-
27-
28-
push:
29-
runs-on: ubuntu-latest
30-
steps:
31-
- uses: actions/checkout@v1
32-
- name: Log into Registry
33-
run: echo "${{ secrets.REGISTRY_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin
34-
- name: Push to GitHub Package Registry
35-
run: make push VERSION=0.0.3
26+

.github/workflows/push.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Push
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*.*.*'
7+
8+
jobs:
9+
push:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v1
13+
- name: Set env
14+
run: echo ::set-env name=RELEASE_VERSION::$(echo ${GITHUB_REF:10})
15+
- name: Log into Registry
16+
run: echo "${{ secrets.REGISTRY_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin
17+
- name: Push to GitHub Package Registry
18+
run: make push VERSION=${{ env.RELEASE_VERSION }}

0 commit comments

Comments
 (0)