Skip to content

Commit

Permalink
[travis][rakefile] only trigger build in SDK repos if not PRs.
Browse files Browse the repository at this point in the history
  • Loading branch information
truthbk committed Feb 23, 2017
1 parent 0883ba4 commit 726479d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ namespace :ci do
desc 'Trigger remote CI'
task :trigger, :repo do |_, args|
abort 'Task only applies to travis builds.' if !ENV['TRAVIS'] || !ENV['TRAVIS_API_TOKEN']
abort 'Task skipped for Pull Requests.' if !ENV['TRAVIS_PULL_REQUEST'].nil? && ENV['TRAVIS_PULL_REQUEST'].casecmp('false')
repo = "DataDog%2F#{args[:repo]}"
url = "https://api.travis-ci.org/repo/#{repo}/requests"
body = { 'request' => { 'branch' => 'master' } }.to_json
Expand Down

0 comments on commit 726479d

Please sign in to comment.