Skip to content

Commit

Permalink
Upgrade scripts using conditional statements
Browse files Browse the repository at this point in the history
  • Loading branch information
jhaemin committed Feb 10, 2020
1 parent 574bdfb commit 1db3bf2
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@
"start": "cross-env HOST=0.0.0.0 nuxt start",
"start-dev": "nuxt start --port 3020",
"deploy": "npm install && npm run pm2-reboot",
"pm2-start": "pm2 start npm --name 'eodiro-client-dist' -- run start",
"pm2-restart": "pm2 restart eodiro-client-dist",
"pm2-stop": "pm2 stop eodiro-client-dist",
"pm2-delete": "pm2 delete eodiro-client-dist",
"pm2-reboot": "npm run pm2-stop && npm run pm2-delete && npm run build && npm run pm2-start",
"pm2-show": "pm2 show eodiro-client-dist",
"pm2-start": "if npm run pm2-show ; then npm run pm2-stop && npm run pm2-start ; else pm2 start npm --name 'eodiro-client-dist' -- run start ; fi",
"pm2-restart": "if npm run pm2-show ; then pm2 restart eodiro-client-dist ; else npm run pm2-no-instance ; fi",
"pm2-stop": "if npm run pm2-show ; then pm2 stop eodiro-client-dist ; else npm run pm2-no-instance ; fi",
"pm2-delete": "if pm2 show eodiro-client ; then pm2 delete eodiro-client-dist ; else npm run pm2-no-instance ; fi",
"pm2-reboot": "if npm run pm2-stop && npm run pm2-delete && npm run build && npm run pm2-start",
"pm2-no-instance": "echo 'No pm2 instance for eodiro client'",
"generate": "nuxt generate",
"add-domain": "echo \"eodiro.com\" > dist/CNAME",
"test": "mocha --require @babel/register"
Expand Down

0 comments on commit 1db3bf2

Please sign in to comment.