-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #125 from trussworks/release-1.2.0
Release 1.2.0
- Loading branch information
Showing
22 changed files
with
2,849 additions
and
1,148 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
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,12 @@ | ||
name: Auto approve | ||
|
||
on: pull_request | ||
|
||
jobs: | ||
auto-approve: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: hmarr/auto-approve-action@v2.0.0 | ||
if: github.actor == 'dependabot[bot]' || github.actor == 'dependabot-preview[bot]' | ||
with: | ||
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,40 @@ | ||
name: Deploy Storybook | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
deploy-storybook: | ||
runs-on: ubuntu-latest | ||
name: Deploy Storybook | ||
steps: | ||
- name: Check out repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Set up node | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: '10.x' | ||
|
||
- name: Get yarn cache directory path | ||
id: yarn-cache-dir-path | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
|
||
- uses: actions/cache@v1 | ||
id: yarn-cache | ||
with: | ||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
- name: Install dependencies | ||
if: steps.yarn-cache.outputs.cache-hit != 'true' | ||
run: yarn install | ||
|
||
- name: Deploy Storybook to Github page | ||
run: yarn storybook:deploy --ci | ||
env: | ||
GH_TOKEN: trussworks:${{ 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
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,8 +1,10 @@ | ||
{ | ||
"plugins": ["stylelint-prettier"], | ||
"plugins": ["stylelint-scss", "stylelint-prettier"], | ||
"rules": { | ||
"at-rule-no-unknown": null, | ||
"scss/at-rule-no-unknown": true, | ||
"prettier/prettier": true, | ||
"selector-class-pattern": "" | ||
}, | ||
"extends": ["stylelint-config-recommended", "stylelint-prettier/recommended", "stylelint-config-sass-guidelines"], | ||
"extends": ["stylelint-config-recommended", "stylelint-prettier/recommended", "stylelint-config-sass-guidelines", "stylelint-config-css-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
Validating CODEOWNERS rules …
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,2 +1 @@ | ||
* @suzubara | ||
* @gidjin | ||
* @suzubara @gidjin @tinyels @sarboc |
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
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,46 @@ | ||
import { includes } from 'lodash'; | ||
import { danger, warn, fail } from 'danger'; | ||
|
||
// No PR is too small to include a description of why you made a change | ||
if (danger.github && danger.github.pr.body.length < 10) { | ||
warn('Please include a description of your PR changes.'); | ||
} | ||
|
||
// load all modified and new files | ||
const allFiles = danger.git.modified_files.concat(danger.git.created_files); | ||
|
||
// Request changes to package source code to also include changes to tests. | ||
const hasCodeChanges = allFiles.some(p => !!p.match(/src\/.*\.[jt]sx?/)); | ||
const hasTestChanges = allFiles.some(p => !!p.match(/src\/.*\.test\.[jt]sx?/)); | ||
if (hasCodeChanges && !hasTestChanges) { | ||
warn('This PR does not include changes to tests, even though it affects source code.'); | ||
} | ||
|
||
// Require new src/components files to include changes to storybook | ||
const hasStorybookChanges = allFiles.some(p => !!p.match(/src\/.*\.stories\.[jt]sx?/)); | ||
|
||
if (hasCodeChanges && !hasStorybookChanges) { | ||
warn('This PR does not include changes to storybook, even though it affects component code.'); | ||
} | ||
|
||
// Request update of yarn.lock if package.json changed but yarn.lock isn't | ||
const packageChanged = includes(allFiles, 'package.json'); | ||
const lockfileChanged = includes(allFiles, 'yarn.lock'); | ||
if (packageChanged && !lockfileChanged) { | ||
const message = 'Changes were made to package.json, but not to yarn.lock'; | ||
const idea = 'Perhaps you need to run `yarn install`?'; | ||
warn(`${message} - <i>${idea}</i>`); | ||
} | ||
|
||
// ensure we have access to github for this check | ||
let isTrivial = false; | ||
if (danger.github) { | ||
isTrivial = includes((danger.github.pr.body + danger.github.pr.title), "#trivial") | ||
} | ||
|
||
// Add a CHANGELOG entry for app changes | ||
const hasChangelog = includes(danger.git.modified_files, "CHANGELOG.md") | ||
|
||
if (!hasChangelog && !isTrivial) { | ||
warn("Please add a changelog entry for your changes.") | ||
} |
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
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
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
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
Oops, something went wrong.