Skip to content

Commit

Permalink
chore: optimize release script to avoid timeouts (#19006)
Browse files Browse the repository at this point in the history
  • Loading branch information
RadhepS authored Jun 26, 2024
1 parent f7e3d10 commit 75e8ca4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
1 change: 1 addition & 0 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
sonar-project.properties
sub-folder/
.pipeline/
tmp/**
9 changes: 7 additions & 2 deletions ci-scripts/release-packer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,15 @@
set -e
shopt -s extglob dotglob

# Build all the libraries and generate the dist folders to use when releasing
function build_libs {
npm ci && npm run build:libs
}

# Configure the project to move everything into a sub-folder to keep root clean for publishing
function configure_project {
mkdir sub-folder
mv !(sub-folder) sub-folder
cd sub-folder
npm ci && npm run build:libs
}

# Clear root containing the old package so the next package can be published
Expand Down Expand Up @@ -49,6 +52,8 @@ function pack {

if [[ $1 == 'configure' ]]; then
configure_project
elif [[ $1 == 'build' ]]; then
build_libs
else
clear_root
pack "$1"
Expand Down

0 comments on commit 75e8ca4

Please sign in to comment.