UNPKG

1.07 kBapplication/x-shView Raw
1#!/bin/bash
2
3set -e
4
5SHA=`git rev-parse --verify HEAD`
6
7git config user.name "Travis CI"
8git config user.email "builds@ethereum.org"
9git checkout --orphan gh-pages
10git rm --cached -r .
11echo "# Automatic build" > README.md
12echo "Built website from {$SHA}. See https://github.com/ethereum/remix/ for details." >> README.md
13# -f is needed because "build" is part of .gitignore
14
15# copying file to the root folder
16cp remix-debugger/index.html index.html
17mkdir build
18cp remix-debugger/build/app.js build/app.js
19mkdir assets
20cp -R remix-debugger/assets/. assets/
21
22git add -f README.md index.html build/app.js assets
23git commit -m "Built website from {$SHA}."
24
25ENCRYPTION_LABEL=fade88419824
26ENCRYPTED_KEY_VAR="encrypted_${ENCRYPTION_LABEL}_key"
27ENCRYPTED_IV_VAR="encrypted_${ENCRYPTION_LABEL}_iv"
28ENCRYPTED_KEY=${!ENCRYPTED_KEY_VAR}
29ENCRYPTED_IV=${!ENCRYPTED_IV_VAR}
30openssl aes-256-cbc -K $ENCRYPTED_KEY -iv $ENCRYPTED_IV -in ci/deploy_key.enc -out deploy_key -d
31chmod 600 deploy_key
32eval `ssh-agent -s`
33ssh-add deploy_key
34
35git push -f git@github.com:ethereum/remix.git gh-pages