Rakefile in platform-api-0.1.0 vs Rakefile in platform-api-0.2.0
- old
+ new
@@ -2,9 +2,15 @@
require 'yard'
desc 'Generate API documentation'
YARD::Rake::YardocTask.new
+desc 'Download the latest schema and build a new client'
+task :build do
+ sh 'curl -o schema.json -H "Accept: application/vnd.heroku+json; version=3" https://api.heroku.com/schema'
+ sh 'bundle exec heroics-generate -H "Accept: application/vnd.heroku+json; version=3" -c "#{Dir.home}/.heroics/platform-api" PlatformAPI schema.json https://api.heroku.com > lib/platform-api/client.rb'
+end
+
desc 'Publish API documentation'
task :publish do
sh 'rake yard'
sh 'cp -R doc /tmp/platform-api-doc'
sh 'git checkout gh-pages'