-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
feat(generate) return non-zero code or page error (#4991) #5195
Merged
Conversation
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
loomchild
commented
Mar 10, 2019
Codecov Report
@@ Coverage Diff @@
## dev #5195 +/- ##
==========================================
+ Coverage 96.31% 96.32% +<.01%
==========================================
Files 73 73
Lines 2472 2474 +2
Branches 626 627 +1
==========================================
+ Hits 2381 2383 +2
Misses 76 76
Partials 15 15
Continue to review full report at Codecov.
|
Introduce --fail-on-page-error option that will cause nuxt generate to return non-zero status code when it encounters a page generation error. This is useful to let CI know that something went wrong.
loomchild
force-pushed
the
feat/generate_non_zero_code
branch
from
March 10, 2019 17:47
1608103
to
e055e73
Compare
pi0
reviewed
Mar 11, 2019
pi0
previously approved these changes
Mar 11, 2019
pimlie
reviewed
Mar 11, 2019
pi0
approved these changes
Mar 11, 2019
Yay, my first PR to Nuxt. Thanks guys! |
@loomchild Great work, that many more may follow! :) |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Introduce --fail-on-page-error option that will cause nuxt generate to return non-zero status code when it encounters a page generation error. This is useful to let CI know that something went wrong.
Types of changes
Description
Resolves: #4991
This PR is a result of the discussion under this ticket and the fact that nuxt-generate-cluster implements similar feature: see nuxt-community/nuxt-generate-cluster#17.
This feature allows
nuxt generate
to return non-zero status code in case of page generation error. This is useful to let CI know that something went wrong, otherwise such issues might get unnoticed for a long time.In order to avoid changing existing behavior and introducing a breaking change I am proposing to add a parameter
--fail-on-page-error
. Only if this parameter is present the error status code will be returned.Checklist:
Note - I am not sure if it requires documentation update and where I should update it, but I am happy to do it if needed. For the moment I have added a option description which will be available when running
nuxt generate --help
.