Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function * run (context) {
const repo = require('../lib/repo')
const app = context.app
let dyno = new Dyno({
heroku: cli.heroku,
app,
attach: true,
command: `set -e
mkdir -p tmp/repo_tmp/unpack
cd tmp/repo_tmp
curl -fo repo-cache.tgz '${yield repo.getCacheURL(app)}'
cd unpack
tar -zxf ../repo-cache.tgz
METADATA="vendor/heroku"
if [ -d "$METADATA" ]; then
TMPDIR=\`mktemp -d\`
cp -rf $METADATA $TMPDIR
fi
cd ..
rm -rf unpack
function * run (context) {
const repo = require('../lib/repo')
const app = context.app
let dyno = new Dyno({
heroku: cli.heroku,
app,
attach: true,
command: `set -e
mkdir -p tmp/repo_tmp/unpack
cd tmp/repo_tmp
curl -fo repo.tgz '${yield repo.getURL(app)}'
cd unpack
tar -zxf ../repo.tgz
git gc --aggressive
tar -zcf ../repack.tgz .
curl -fo /dev/null --upload-file ../repack.tgz '${yield repo.putURL(app)}'
exit`
})
yield dyno.start()
}