mirror of
https://github.com/docker/login-action.git
synced 2024-11-23 23:55:07 +08:00
Add ci and pre-checkin workflow
This commit is contained in:
parent
64f9c325fc
commit
fda7d266a6
28
.github/workflows/ci.yml
vendored
Normal file
28
.github/workflows/ci.yml
vendored
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
name: ci
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
- releases/v*
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
main:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
logout:
|
||||||
|
- true
|
||||||
|
- false
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@v2.3.1
|
||||||
|
-
|
||||||
|
name: Login
|
||||||
|
uses: ./login/
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME_TEST }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD_TEST }}
|
||||||
|
logout: ${{ matrix.logout }}
|
30
.github/workflows/pre-checkin.yml
vendored
Normal file
30
.github/workflows/pre-checkin.yml
vendored
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
name: pre-checkin
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
paths-ignore:
|
||||||
|
- '**.md'
|
||||||
|
pull_request:
|
||||||
|
paths-ignore:
|
||||||
|
- '**.md'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
pre-checkin:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@v2.3.1
|
||||||
|
-
|
||||||
|
name: Install
|
||||||
|
run: yarn install
|
||||||
|
-
|
||||||
|
name: Pre-checkin
|
||||||
|
run: yarn run pre-checkin
|
||||||
|
-
|
||||||
|
name: Check for uncommitted changes
|
||||||
|
run: |
|
||||||
|
if [[ `git status --porcelain` ]]; then
|
||||||
|
git status --porcelain
|
||||||
|
echo "::warning::Found changes. Please run 'yarn run pre-checkin' and push"
|
||||||
|
fi
|
Loading…
Reference in New Issue
Block a user