mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
build: better error reporting of bash scripts (#5397)
Currently whenever something fails in the deploy script it will likely not cause the CI to show the failure. This is because Bash by default doesn't exit the process with the proper error code.
This commit is contained in:
committed by
tinayuangao
parent
69bea28186
commit
d859d34739
@@ -1,5 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
# The script should immediately exit if any command in the script fails.
|
||||
set -e
|
||||
|
||||
echo ""
|
||||
|
||||
@@ -3,6 +3,9 @@
|
||||
# Script that runs after the testing stage of Travis passed.
|
||||
# Build artifacts and docs content will be published to different repositories.
|
||||
|
||||
# The script should immediately exit if any command in the script fails.
|
||||
set -e
|
||||
|
||||
# Go to the project root directory
|
||||
cd $(dirname $0)/../..
|
||||
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
# The script should immediately exit if any command in the script fails.
|
||||
set -e
|
||||
|
||||
# This script deploys the Dashboard App and their Cloud Functions to Firebase.
|
||||
# Before the script installs all dependencies and builds the dashboard app in production.
|
||||
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
# The script should immediately exit if any command in the script fails.
|
||||
set -e
|
||||
|
||||
# Go to the project root directory
|
||||
cd $(dirname ${0})/../..
|
||||
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
# Script to publish the build artifacts to a GitHub repository.
|
||||
# Builds will be automatically published once new changes are made to the repository.
|
||||
|
||||
set -e -o pipefail
|
||||
# The script should immediately exit if any command in the script fails.
|
||||
set -e
|
||||
|
||||
# Go to the project root directory
|
||||
cd $(dirname ${0})/../..
|
||||
|
||||
@@ -3,6 +3,9 @@
|
||||
# Publish material2 docs assets to the material2-docs-content repo
|
||||
# material.angular.io will pull from this assets repo to get the latest docs
|
||||
|
||||
# The script should immediately exit if any command in the script fails.
|
||||
set -e
|
||||
|
||||
cd "$(dirname $0)/../../"
|
||||
|
||||
docsPath="./dist/docs"
|
||||
|
||||
Reference in New Issue
Block a user