Commit 6c607e09 authored by lislis's avatar lislis

write copy script

parent 06aa2b45
Pipeline #57683381 passed with stages
in 1 minute and 4 seconds
......@@ -10,12 +10,8 @@ cache:
pages:
script:
- npm run build
- mkdir public && chmod -R 755 public && cd public
- cp ../index.html .
- cp ../main.css .
- cp ../bundle.js .
- mkdir assets && chmod -R 755 assets && cp -r ../assets/*.png assets/
- ls -al
- npm run package
- ls -al public
artifacts:
untracked: true
......
# F.U.C.K. map
## Install dependencies
``` bash
$ npm install
```
## Dev server
``` bash
$ npm run start
```
## Build JS and copy to public/
``` bash
$ npm run build && npm run package
```
......@@ -4,7 +4,8 @@
"main": "index.js",
"scripts": {
"start": "budo index.js:bundle.js -p 3000 --no-debug -- -b bundle-collapser/plugin -g unassertify -g yo-yoify -g uglifyify",
"build": "npx browserify index.js -o bundle.js"
"build": "npx browserify index.js -o bundle.js",
"package": "./scripts/package.sh"
},
"license": "MIT",
"dependencies": {
......
#!/bin/bash
set -e
mkdir public && chmod -R 755 public
cp index.html public/
cp main.css public/
cp bundle.js public/
cp fucks.json public/
mkdir public/assets && chmod -R 755 public/assets && cp -r assets/*.png public/assets/
echo "Copied to public/ folder"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment