forked from DTLab-LabCN/DTT-Docs
-
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.
fix(doc and launching): added a launch script and updated documentation.
- Loading branch information
1 parent
44316fe
commit 1b5dc85
Showing
2 changed files
with
33 additions
and
13 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
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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#! /usr/bin/env bash | ||
if ! which -s npm; then | ||
echo "Please install Node.js, node version specified here https://docusaurus.io/docs/installation (at least 18.0)" | ||
else | ||
echo "Current node version is [$(node --version)]" | ||
fi | ||
|
||
set -e | ||
|
||
echo "Sourcing .env.sample" | ||
# Variables in .env.sample file could be customised | ||
# but this is not necessary for local-only testing | ||
# Note that the `build` step below will fail if the relevant | ||
# environment variables are not set | ||
source .env.sample | ||
|
||
set -x | ||
|
||
# This only really required at the very first run and each time there is | ||
# a modification of either `package.json` or `package-lock.json` | ||
# However running it systematically does not take much time and does no harm | ||
npm install | ||
|
||
npm run build && npm run start |