File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -18,8 +18,8 @@ task :deploy => [:check_git] do
1818
1919 puts "...git pull origin \" #{ source_branch } \" "
2020 system "git pull origin \" #{ source_branch } \" "
21- # puts "...update plot schema"
22- # system "curl https://api.plot.ly/v2/plot-schema?sha1=%27%27 > _data/plotschema.json && git add _data/plotschema.json && git commit -m \"Updated plotschema at #{Time.now.utc}\" && git push origin \"#{source_branch}\""
21+ puts "...update plot schema"
22+ system "python ./get_plotschema.py && git add _data/plotschema.json && git commit -m \" Updated plotschema at #{ Time . now . utc } \" && git push origin \" #{ source_branch } \" "
2323 puts "...generate _site"
2424 system "jekyll build --verbose && git checkout \" #{ deploy_branch } \" && git pull origin \" #{ deploy_branch } \" && cp -r _site/* . && rm -rf _site/ && touch .nojekyll && git add . && git commit -m \" #{ message } \" && git push origin \" #{ deploy_branch } \" "
2525 puts "...git checkout \" #{ source_branch } \" "
Original file line number Diff line number Diff line change 1+ """
2+ Update _data/plotschema.json for rakefile.
3+ """
4+ import requests
5+
6+ plotschema = requests .get ('https://api.plot.ly/v2/plot-schema/?sha1=%27%27' ,
7+ headers = {'plotly-client-platform' : 'python' },
8+ auth = ('plotly_docs' , 'ikwqmjam2o' )).content
9+ f = open ('_data/plotschema.json' , 'w' )
10+ f .write (plotschema )
You can’t perform that action at this time.
0 commit comments