-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: create action * chore: build Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
- Loading branch information
1 parent
8d0d597
commit 6eb1f22
Showing
23 changed files
with
11,152 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
dist/ | ||
lib/ | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
module.exports = { | ||
extends: [ | ||
'plugin:@typescript-eslint/recommended', | ||
'airbnb-typescript/base', | ||
'plugin:prettier/recommended', | ||
], | ||
parser: '@typescript-eslint/parser', | ||
plugins: ['@typescript-eslint'], | ||
parserOptions: { | ||
ecmaVersion: 9, | ||
sourceType: 'module', | ||
project: './tsconfig.json', | ||
}, | ||
rules: { | ||
// No default exports | ||
'import/no-default-export': 'error', | ||
'import/prefer-default-export': 'off', | ||
|
||
// Enforce import order and no spaces | ||
'import/order': [ | ||
'error', | ||
{ | ||
alphabetize: { order: 'asc', caseInsensitive: true }, | ||
'newlines-between': 'never', | ||
}, | ||
], | ||
|
||
// Sort import members | ||
'sort-imports': [ | ||
'error', | ||
{ | ||
ignoreCase: true, | ||
ignoreDeclarationSort: true, | ||
ignoreMemberSort: false, | ||
}, | ||
], | ||
}, | ||
env: { | ||
node: true, | ||
es6: true, | ||
}, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
dist/** -diff linguist-generated=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: npm | ||
directory: / | ||
schedule: | ||
interval: daily | ||
|
||
- package-ecosystem: github-actions | ||
directory: / | ||
schedule: | ||
interval: daily |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Test & Build | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
token: ${{ secrets.PERSONAL_ACCESS_TOKEN }} | ||
- run: yarn | ||
- run: yarn tsc | ||
- run: yarn lint | ||
- run: yarn build | ||
- uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
commit_message: 'chore: build' | ||
commit_author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | ||
commit_user_name: github-actions[bot] | ||
commit_user_email: 41898282+github-actions[bot]@users.noreply.github.com> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
name: Check PR title | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
- reopened | ||
- edited | ||
- synchronize | ||
|
||
jobs: | ||
check-pr-title: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: amannn/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: GoogleCloudPlatform/release-please-action@v2 | ||
id: release | ||
with: | ||
release-type: node | ||
|
||
- uses: actions/checkout@v2 | ||
- name: tag major versions | ||
if: ${{ steps.release.outputs.release_created }} | ||
run: | | ||
git config user.name github-actions[bot] | ||
git config user.email 41898282+github-actions[bot]@users.noreply.github.com | ||
git remote add gh-token "https://${{ secrets.GITHUB_TOKEN }}@github.com/google-github-actions/release-please-action.git" | ||
git tag -d v${{ steps.release.outputs.major }} || true | ||
git push origin :v${{ steps.release.outputs.major }} || true | ||
git tag -a v${{ steps.release.outputs.major }} -m "Release v${{ steps.release.outputs.major }}" | ||
git push origin v${{ steps.release.outputs.major }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
lib/ | ||
node_modules/ | ||
|
||
*.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
dist/ | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"semi": false, | ||
"tabWidth": 2, | ||
"singleQuote": true, | ||
"trailingComma": "all" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* @theappnest/devops |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,26 @@ | ||
# github-skip-checks-action | ||
|
||
This GitHub action marks checks as successful if no changes occurred to specified files. | ||
|
||
## Usage | ||
|
||
```yaml | ||
jobs: | ||
skip_checks: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: theappnest/github-skip-checks-action@master | ||
with: | ||
paths: | | ||
foo/** | ||
bar/** | ||
checks: | | ||
lint-foo-bar | ||
test-foo-bar | ||
``` | ||
## Inputs | ||
- `token` (optional) GitHub token. Defaults to secrets.GITHUB_TOKEN. | ||
- `paths` List of path globs to check for changes. | ||
- `checks` List of checks to mark as successful. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
name: terraform-monorepo-action | ||
description: Marks checks as successful if no changes occurred to specified files. | ||
author: DREST LTD | ||
inputs: | ||
token: | ||
description: GitHub token. Defaults to secrets.GITHUB_TOKEN. | ||
required: false | ||
default: ${{ github.token }} | ||
paths: | ||
description: List of path globs to check for changes. | ||
required: true | ||
checks: | ||
description: List of checks to mark as successful. | ||
required: true | ||
runs: | ||
using: 'node12' | ||
main: 'dist/index.js' |
Oops, something went wrong.