Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add npm scripts to copy static resources to dist #64

Open
jskrzypek opened this issue Apr 5, 2016 · 1 comment
Open

Add npm scripts to copy static resources to dist #64

jskrzypek opened this issue Apr 5, 2016 · 1 comment

Comments

@jskrzypek
Copy link
Contributor

  "scripts": {
    "prebuild": "npm run copy:all",
    "build": "node --max-old-space-size=4096 ./node_modules/webpack/bin/webpack --progress --profile --display-error-details --display-cached",
    "prewatch": "npm run copy:all",
    "watch": "node --max-old-space-size=4096 ./node_modules/webpack/bin/webpack --watch --progress --profile --display-error-details --display-cached",
    "clean": "rimraf dist coverage reports",
    "copy:all": "npm run copy:resources && npm run copy:fonts &&  npm run copy:fuse",
    "copy:resources": "mkdir -p dist/${TARGET-app}/${MODE-dev} && cp -r client/resources dist/${TARGET-app}/${MODE-dev}",
    "copy:fonts": "mkdir -p dist/${TARGET-app}/${MODE-dev} && cp -r client/fonts dist/${TARGET-app}/${MODE-dev}",
    "copy:fuse": "if [ -f client/scripts/${TARGET-app}/index.ux ]; then mkdir -p dist/${TARGET-app}/${MODE-dev}/fuse && cp -r fuse/*.js dist/${TARGET-app}/${MODE-dev}/fuse; fi",
    ...
    "prefuse:preview": "npm run copy:all",
    "fuse:preview": "cd dist/${TARGET-app}/${MODE-dev} && fuse preview",
    "prefuse:ios": "npm run copy:all",
    "fuse:ios": "cd dist/${TARGET-app}/${MODE-dev} && fuse build --target=iOS --run",
    "prefuse:android": "npm run copy:all",
    "fuse:android": "cd dist/${TARGET-app}/${MODE-dev} && fuse build --target=Android --run",
    ...
  }
@thaiat
Copy link
Contributor

thaiat commented Apr 6, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants