-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from techstartucalgary/Aarsh/Quick-Script-Addi…
…tion updated script to allow for skipping of the init
- Loading branch information
Showing
2 changed files
with
37 additions
and
22 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,5 +47,7 @@ backend/dist | |
backend/coverage | ||
backend/coverage/* | ||
|
||
frontend/%ProgramData% | ||
|
||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,45 @@ | ||
#!/bin/bash | ||
|
||
cd scripts || exit | ||
# Check if --skip flag is passed | ||
SKIP=false | ||
for arg in "$@" | ||
do | ||
if [ "$arg" == "--skip" ]; then | ||
SKIP=true | ||
break | ||
fi | ||
done | ||
|
||
# Call the installation script | ||
./install.sh | ||
if [ "$SKIP" = false ]; then | ||
cd scripts || exit | ||
|
||
# Determine the OS type and call the appropriate IP script | ||
OS_TYPE=$(uname -s) | ||
case "$OS_TYPE" in | ||
Linux*|Darwin*) | ||
# This is for Unix-like systems | ||
./ipscriptUNIX.sh ../backend/.env | ||
./ipscriptUNIX.sh ../frontend/.env | ||
;; | ||
MINGW*|CYGWIN*|MSYS*) | ||
# This is for Windows Git Bash | ||
./ipscript.sh ../backend/.env | ||
./ipscript.sh ../frontend/.env | ||
;; | ||
*) | ||
echo "Unknown operating system." | ||
exit 1 | ||
;; | ||
esac | ||
# Call the installation script | ||
./install.sh | ||
|
||
cd .. || exit | ||
# Determine the OS type and call the appropriate IP script | ||
OS_TYPE=$(uname -s) | ||
case "$OS_TYPE" in | ||
Linux*|Darwin*) | ||
# This is for Unix-like systems | ||
./ipscriptUNIX.sh ../backend/.env | ||
./ipscriptUNIX.sh ../frontend/.env | ||
;; | ||
MINGW*|CYGWIN*|MSYS*) | ||
# This is for Windows Git Bash | ||
./ipscript.sh ../backend/.env | ||
./ipscript.sh ../frontend/.env | ||
;; | ||
*) | ||
echo "Unknown operating system." | ||
exit 1 | ||
;; | ||
esac | ||
|
||
cd .. || exit | ||
|
||
# Use nvm to switch to the specified version of Node.js, install dependencies, and start the application | ||
nvm use 18.13.0 || : | ||
npm install | ||
fi | ||
|
||
npm run start |