Skip to content

Commit

Permalink
Improved build script
Browse files Browse the repository at this point in the history
  • Loading branch information
joerx committed Mar 13, 2016
1 parent 3039bd5 commit 86849e2
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 17 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Expand Up @@ -69,4 +69,7 @@ target/

# node.js
node_modules/
.env
.env


fa16-repo/
6 changes: 3 additions & 3 deletions .travis.yml
Expand Up @@ -3,9 +3,9 @@ python:
- "2.7"
install: pip install -r requirements.txt
before_script:
- nvm install 5.8
- nvm alias default 5.8
- nvm install 4.4
- nvm alias default 4.4
- npm install
script: npm run scraper && npm run generator && sh push-2016.fossasia.org.sh
script: sh build.sh
env:
- secure: "MA928kGtPidi9F5ciZOogrQnNTZKWPESFq9ew9Mw0wVLu9evcJlFa5WoYXkmOn72hM8qEwoD66R7zb9b+0QS8uHop9QvjG1cjpslzorjE08BU0aMlsx98STPVWB5l8aNOPGE3qhFJmOWm6c+B8lNph61nTMR/4oQ+3+kFvMj4SX9QJ3zZ+VxP/Be5uMkpwySbH9t4rByI4dcvOnwpnsxeuxE7HktNUbuJeAh5nuWuWUgfDrvG2FGgp85zZBQtBTUVAb7ggLNJbdNz6hKOjrVYefqa0bOsoFjbyAtb2vNmfHSsg/xUfBQ/4SSsfYU5jv/uuyp+mdbEb0TLejMNjOCUsIq6bIUe2XgQHJhhHrEtZsUVQEC/1bckxgDFYbmDJcbOQt9j+QAppPkhAoq71IzOnycpmM5zGEZUoOxRIay//Dyg3QyPOJ0Jswce6zKuy8DV5K9aInGBscyY/6Q6Zab7vn0cOYhKEVMSzpKlz4TxGvQm8FGUOqaFFBoxoZlmjzyIeWYqiKRwt7FJgXKEyjbFn8uwt1lZze535eytVgW4Rx4g5QkW6HCQcsQQe0Shqkfb8feDICCw5xPLwUvutrU9/s9HCN/wxpE8nUHhGsODyUl41hCkvocL608wDutgJjhBrQod3wu81Bn8O+ZM/C0XUgvH5LAMxpaMVxg9lMs2Ns="
23 changes: 23 additions & 0 deletions build.sh
@@ -0,0 +1,23 @@
# thanks to https://gist.github.com/domenic/ec8b0fc8ab45f39403dd
#!/bin/sh
set -e

git clone --depth=1 "https://${GH_TOKEN}@github.com/fossasia/2016.fossasia.org" fa16-repo

python scraper.py
node schedule/generator > fa16-repo/schedule/index.html

cd fa16-repo
git config user.name "Travis CI"
git config user.email "noreply+travis@fossasia.org"

CHANGED=$(git status -s)
if [ "$CHANGED" != "" ]
then
git commit -am '[Auto] updated schedule'
git push origin gh-pages
else
echo "no changes"
fi

exit 0
13 changes: 0 additions & 13 deletions push-2016.fossasia.org.sh

This file was deleted.

0 comments on commit 86849e2

Please sign in to comment.