Skip to content

Commit

Permalink
Merge pull request #37 from twitter-base/gh-actions
Browse files Browse the repository at this point in the history
Gh actions
  • Loading branch information
dezren39 authored Sep 16, 2020
2 parents 183d657 + f24cddc commit 83e25d8
Show file tree
Hide file tree
Showing 23 changed files with 208 additions and 8,183 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/auto-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Dependabot Auto-Merge

on:
pull_request:

jobs:
auto-merge:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: ahmadnassri/action-dependabot-auto-merge@v2
with:
target: minor
github-token: ${{ secrets.GITHUB_TOKEN }}
35 changes: 35 additions & 0 deletions .github/workflows/base-branch.check.protected.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Base-Branch Check Protected [PR]
on:
pull_request:
branches:
- 'main'
- 'next'
- 'dev'
jobs:
check-pr-base-branch-protected:
runs-on: ubuntu-latest
steps:
- if: github.ref == 'refs/heads/main'
name: Base-branch check - main
uses: a-b-r-o-w-n/check-base-branch-action@v1
with:
protectedBranches: "next"
defaultBranch: "dev"
update-branch: false
repo-token: "${{ secrets.GITHUB_TOKEN }}"
- if: github.ref == 'refs/heads/next'
name: Base-branch check - next
uses: a-b-r-o-w-n/check-base-branch-action@v1
with:
protectedBranches: "dev"
defaultBranch: "main"
update-branch: false
repo-token: "${{ secrets.GITHUB_TOKEN }}"
- if: github.ref == 'refs/heads/dev'
name: Base-branch check - dev
uses: a-b-r-o-w-n/check-base-branch-action@v1
with:
protectedBranches: "main"
defaultBranch: "next"
update-branch: true
repo-token: "${{ secrets.GITHUB_TOKEN }}"
18 changes: 18 additions & 0 deletions .github/workflows/base-branch.check.unprotected.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Base-Branch Check Unprotected [PR]
on:
pull_request:
branches-ignore:
- 'main'
- 'next'
- 'dev'
jobs:
check-pr-base-branch-unprotected:
runs-on: ubuntu-latest
steps:
- name: Base-branch check - feature - unprotected
uses: a-b-r-o-w-n/check-base-branch-action@v1
with:
protectedBranches: "main, next"
defaultBranch: "dev"
update-branch: true
repo-token: "${{ secrets.GITHUB_TOKEN }}"
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
name: Check
name: Install, Build, Test [node]
on: [push, pull_request, pull_request_target, create, fork, release]
jobs:
check:
install-build-test:
runs-on: ubuntu-latest
strategy:
matrix:
node: [ '14', '12', '10' ]
name: Check - Node.js - ${{ matrix.node }}
pm: [ 'yarn', 'npm' ]
name: Install, Build, Test - ${{ matrix.pm }}(${{ matrix.node }})
steps:
- name: Checkout repository
uses: actions/checkout@v2
Expand All @@ -16,8 +17,8 @@ jobs:
node-version: ${{ matrix.node }}
check-latest: true
- name: Install dependencies
run: yarn install #--immutable --immutable-cache --check-cache
run: ${{ matrix.pm }} install #--immutable --immutable-cache --check-cache
- name: Build target
run: yarn build
run: ${{ matrix.pm }} build
- name: Test code
run: yarn test
run: ${{ matrix.pm }} test
15 changes: 15 additions & 0 deletions .github/workflows/merge.main.dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
on:
push:
branches:
- "main"
jobs:
merge-branch:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: everlytic/[email protected]
with:
github_token: ${{ github.token }}
source_ref: ${{ github.ref }}
target_branch: 'dev'
commit_message_template: 'chore(backmerge) [Automated] [skip ci] Merged {source_ref} into target {target_branch}'
18 changes: 18 additions & 0 deletions .github/workflows/release-notes.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Release-Notes-Preview

on:
[pull_request, issue_comment]

jobs:
preview:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: |
git fetch --prune --unshallow --tags
- uses: snyk/[email protected]
with:
releaseBranch: main
env:
GITHUB_PR_USERNAME: ${{ github.actor }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions .github/workflows/release.dry-run.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
name: Release DRY-RUN
name: Release (DRY-RUN) [node,gh,npm]
on: [push, pull_request, pull_request_target, create, fork, release]
jobs:
release_dry-run:
runs-on: ubuntu-latest
strategy:
matrix:
node: [ '14' ]
name: Release DRY-RUN - Node.js - ${{ matrix.node }}
name: Release (DRY-RUN) - yarn(${{ matrix.node }})
steps:
- name: Checkout repository
uses: actions/checkout@v2
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release Package
name: Release Package [node,gh,npm]
on:
push:
branches:
Expand All @@ -21,7 +21,7 @@ jobs:
strategy:
matrix:
node: [ '14' ]
name: Release - Node.js - ${{ matrix.node }}
name: Release - yarn(${{ matrix.node }})
steps:
- name: Checkout repository
uses: actions/checkout@v2
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added .yarn/cache/fs-npm-0.0.2-bba8c78dbd-ce207ac556.zip
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified .yarn/install-state.gz
Binary file not shown.
Loading

0 comments on commit 83e25d8

Please sign in to comment.