Skip to content

Commit

Permalink
#5: Create CI configuration and a build script
Browse files Browse the repository at this point in the history
 - corrected a typo ('artifact' < 'artefact')
  • Loading branch information
dartandrevinsky committed Apr 22, 2021
1 parent bf614ad commit 29cf0a0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
- checkout
- run:
command: |
export CI_ARTEFACTS_PATH=~/ftgo-consumer-web-ui/ci-artefacts |
export CI_ARTIFACTS_PATH=~/ftgo-consumer-web-ui/ci-artifacts |
export JEST_JUNIT_OUTPUT_DIR_PARENT=~/ftgo-consumer-web-ui/reports |
./build-and-test-all.sh
- store_test_results:
path: ~/ftgo-consumer-web-ui/reports
- store_artifacts:
path: ~/ftgo-consumer-web-ui/ci-artefacts
path: ~/ftgo-consumer-web-ui/ci-artifacts

12 changes: 6 additions & 6 deletions build-and-test-all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ if [[ -z "$JEST_JUNIT_OUTPUT_DIR" ]]; then
mkdir -p "$JEST_JUNIT_OUTPUT_DIR"
fi

if [[ -z "$CI_ARTEFACTS_PATH" ]]; then
export CI_ARTEFACTS_PATH=$(pwd)/ci-artefacts/
mkdir -p "$CI_ARTEFACTS_PATH"
if [[ -z "$CI_ARTIFACTS_PATH" ]]; then
export CI_ARTIFACTS_PATH=$(pwd)/ci-artifacts/
mkdir -p "$CI_ARTIFACTS_PATH"
fi
mkdir -p "$CI_ARTEFACTS_PATH/npm-logs"
mkdir -p "$CI_ARTIFACTS_PATH/npm-logs"


echo ""
Expand Down Expand Up @@ -58,9 +58,9 @@ echo ""
echo ""
echo "50. Archiving and copying the resulted built files"

tar -czvf "$CI_ARTEFACTS_PATH/build_$(date '+%Y%m%d_%H%M').tar.gz" build
tar -czvf "$CI_ARTIFACTS_PATH/build_$(date '+%Y%m%d_%H%M').tar.gz" build

cp ./junit.xml "$JEST_JUNIT_OUTPUT_DIR/junit_$(date '+%Y%m%d_%H%M').xml" 2>/dev/null || :

echo "Copy NPM logs"
[ -d "$HOME/.npm/_logs" ] && cp -R ~/.npm/_logs/* "$CI_ARTEFACTS_PATH/npm-logs" 2>/dev/null || :
[ -d "$HOME/.npm/_logs" ] && cp -R ~/.npm/_logs/* "$CI_ARTIFACTS_PATH/npm-logs" 2>/dev/null || :

0 comments on commit 29cf0a0

Please sign in to comment.