Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure CI fails on non-prettier compliant PRs #693

Merged
merged 2 commits into from Jan 1, 2018
Merged

Ensure CI fails on non-prettier compliant PRs #693

merged 2 commits into from Jan 1, 2018

Conversation

james-prado
Copy link
Contributor

Closes MyEtherWallet/MyEtherWallet#601

@james-prado james-prado added the status: ready for review Open PR's that are ready for technical review. Replaced with "changes needed" or "ready to merge". label Dec 30, 2017
package.json Outdated
"prettier --write --config ./.prettierrc --list-different \"common/**/*.ts\"",
"prettier:diff-tsx":
"prettier --write --config ./.prettierrc --list-different \"common/**/*.tsx\"",
"prettier:diff": "npm run prettier:diff-ts && npm run prettier:diff-tsx",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need both prettier:diff-tsx and prettier:diff-ts, a single regex should be able to accommodate both.

.travis.yml Outdated
@@ -20,6 +20,8 @@ install:

jobs:
include:
- stage: Prettier Diff
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why run it in a different stage?

.travis.yml Outdated
@@ -20,6 +20,8 @@ install:

jobs:
include:
- stage: Prettier Diff
script: npm run prettier:diff
Copy link
Contributor

@dternyak dternyak Jan 1, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To confirm, --list-different returns a non-zero exit code if there are any different files?

@dternyak dternyak changed the title Check prettier diff in ci Ensure CI Fails on non-prettier compliant PRs Jan 1, 2018
@dternyak dternyak changed the title Ensure CI Fails on non-prettier compliant PRs Ensure CI fails on non-prettier compliant PRs Jan 1, 2018
@dternyak dternyak merged commit 23e99e5 into MyCryptoHQ:develop Jan 1, 2018
@james-prado james-prado deleted the prettier-ci-script branch January 15, 2018 22:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: ready for review Open PR's that are ready for technical review. Replaced with "changes needed" or "ready to merge".
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants