npm scripts - theRAPTLab/gsgo GitHub Wiki
-
npm run bootstrap
-- runs lerna bootstrap, which is a distinct operation from building the libraries. It's essentially part of package management. It essentially deletes ALL the node_modules directories, reinitializes each project in gs_packages, then figures out which ones are common and can be moved to the top-level so there aren't duplicates, and rewrites links as necessary (or it used to, npm may have changed). Bootstrap is only needed when adding any package through npm install . You should always run bootstrap afterwards. -
npm start
-- runsbuild
and multiviewgem
-
npm run mcp
-- runs the asset server, without all the gemsrv stuff. This is used to test the asset server stand-alone -
npm run build
-- builds everything, including URSYS so it generates the target libraries client.js and server.js that what is actually loaded when doing theimport UR from '@gemstep/ursys/client'
The reasonnpm run build
is necessary is because when the gsgo repo is downloaded, the "library version" of URSYS has not yet been compiled intoserver.js
andclient.js
; these are what are loaded by:-
import * as UR from '@gemstep/ursys/client'
on the client side -
const UR = require('@gemstep/ursys/server')
for server code:
The
client.js
andserver.js
files are not committed to the repo currently, but we could probably allow them now that they are fairly stable. -
-
npm run gem
-- NOTE does NOT build the system. The reason for taking it out was because it would double or triple build when I was doing development simultaneously on URSYS and GEMSRV codebases. If you are NOT making changes to URSYS, you can instead just donpm run build
afternpm run bootstrap
for a fresh install, but for the researcher end user case just doingnpm run start
after the bootstrap should be sufficient.
Special Development Scripts
-
npm run ursys
-- a live compiler for the URSYS library for when Sri is modifying it when also modifying GEM server. Just for developing ursys using live reload -
npm run sridev
-- special script just for Sri's development process -
*:multi
-- creates multiple column views
Deprecated Scripts
-
npm run admin
-- old admin panel mockup
See also
- #335