forked from reduxframework/redux-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathupdate-mirrors-docs.sh
executable file
·42 lines (29 loc) · 989 Bytes
/
update-mirrors-docs.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#!/usr/bin/env bash
#&& "$TRAVIS_PHP_VERSION" >= 5.3
if [[ "$TRAVIS_PULL_REQUEST" == "false" && "$TRAVIS_JOB_NUMBER" == *.1 ]]; then
# Update the mirror repo for composer/packagist
git push --mirror https://${GH_TOKEN}@github.com/redux-framework/redux-framework.git
# Re-Deploy the heroku demo app and pull the newest code
git clone [email protected]:redux-premium.git
cd redux-premium
git reset HEAD~; git push -f heroku master;
cd ..
# cd ..
# rm -fr $HOME/redux-premium
echo -e "Starting to update documentation\n"
# Make sure we don't have any old files
rm -fr $HOME/docs
# Install phpDocumentor
pear channel-discover pear.phpdoc.org
pear install phpdoc/phpDocumentor
pear install Image_GraphViz
phpenv rehash #Have to run this for travis
# Generate the docs
grunt phpdocumentor
# Copy the github CNAME file to the docs
cp bin/CNAME docs/
# Publish the docs to gh-pages
grunt gh-pages:travis
# Clean out the docs directory
#git rm -fr $HOME/docs/
fi