Merge pull request #126 from 67P/dev/production_builds
Improve production builds and deployment
This commit was merged in pull request #126.
This commit is contained in:
+4
-3
@@ -17,9 +17,10 @@
|
|||||||
"start": "KREDITS_APM_DOMAIN=open.aragonpm.eth ember serve",
|
"start": "KREDITS_APM_DOMAIN=open.aragonpm.eth ember serve",
|
||||||
"start:local": "WEB3_PROVIDER_URL=http://localhost:7545 ember s",
|
"start:local": "WEB3_PROVIDER_URL=http://localhost:7545 ember s",
|
||||||
"build": "ember build",
|
"build": "ember build",
|
||||||
"build-prod": "ember build --environment production",
|
"build-prod": "rm -rf release/* && ember build -prod --output-path release",
|
||||||
"update-version-file": "bash scripts/update-version-file.sh",
|
"preversion": "npm test",
|
||||||
"deploy": "npm run build-prod && npm run update-version-file && bash scripts/deploy.sh"
|
"version": "npm run build-prod && git add release/",
|
||||||
|
"deploy": "git push 5apps master"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@ember/jquery": "^0.5.2",
|
"@ember/jquery": "^0.5.2",
|
||||||
|
|||||||
@@ -1,20 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
set -xe
|
|
||||||
|
|
||||||
# Get revision from local master
|
|
||||||
rev=`git rev-parse HEAD`
|
|
||||||
short_rev=${rev:0:7}
|
|
||||||
# Check out build branch
|
|
||||||
git checkout build-production
|
|
||||||
# Copy from build dir to root
|
|
||||||
cp -r dist/* .
|
|
||||||
# Add all files
|
|
||||||
git add --all
|
|
||||||
# Commit build files
|
|
||||||
git commit -m "Build production from $short_rev"
|
|
||||||
# Push to remote
|
|
||||||
git push 5apps build-production:master
|
|
||||||
# Push build branch to collab repo
|
|
||||||
git push origin build-production:build-production
|
|
||||||
# Go back to previous branch
|
|
||||||
git checkout -
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
PACKAGE_VERSION=$(cat package.json \
|
|
||||||
| grep version \
|
|
||||||
| head -1 \
|
|
||||||
| awk -F: '{ print $2 }' \
|
|
||||||
| sed 's/[",]//g' \
|
|
||||||
| tr -d '[[:space:]]')
|
|
||||||
|
|
||||||
echo $PACKAGE_VERSION > dist/VERSION
|
|
||||||
Reference in New Issue
Block a user