Procházet zdrojové kódy

For Travis CI - fix rake ci_rebase task.
Test [ci scan] on demand.

Yao Wei Tjong 姚伟忠 před 10 roky
rodič
revize
0b64216424
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      Rakefile

+ 1 - 1
Rakefile

@@ -273,7 +273,7 @@ task :ci_rebase do
   baseline = ENV['RELEASE_TAG'] || "origin/#{ENV['TRAVIS_BRANCH']}"
   baseline = ENV['RELEASE_TAG'] || "origin/#{ENV['TRAVIS_BRANCH']}"
   rebase = /\[ci rebase\]/ =~ ENV['COMMIT_MESSAGE']
   rebase = /\[ci rebase\]/ =~ ENV['COMMIT_MESSAGE']
   scan = /\[ci scan\]/ =~ ENV['COMMIT_MESSAGE'] || ENV['PACKAGE_UPLOAD']  # Limit the frequency of scanning
   scan = /\[ci scan\]/ =~ ENV['COMMIT_MESSAGE'] || ENV['PACKAGE_UPLOAD']  # Limit the frequency of scanning
-  ['Coverity-Scan', 'Android-CI', 'RPI-CI', 'OSX-CI', 'Emscripten-CI'].each { |ci| ci_branch = ENV['RELEASE_TAG'] || ENV['TRAVIS_BRANCH'] == 'master' ? ci : "#{ENV['TRAVIS_BRANCH']}-#{ci}"; system "if git fetch origin #{ci_branch}:#{ci_branch} 2>/dev/null; then if [ #{scan} ] || [ #{/Scan/ =~ ci} ]; then git rebase #{baseline} #{ci_branch} && git push -qf -u origin #{ci_branch} >/dev/null 2>&1; fi; elif [ #{rebase} ]; then git checkout -b #{ci_branch} #{ENV['TRAVIS_BRANCH']} && rm .travis.yml && wget -q https://raw.githubusercontent.com/#{ENV['TRAVIS_REPO_SLUG']}/#{ci}/.travis.yml && git add -A . && git commit -m 'For Travis CI - switch CI build to use #{ci.split('-').first} build environment.' && git push -qf -u origin #{ci_branch} >/dev/null 2>&1; fi" or abort "Failed to rebase #{ci_branch} mirror branch" }
+  ['Coverity-Scan', 'Android-CI', 'RPI-CI', 'OSX-CI', 'Emscripten-CI'].each { |ci| ci_branch = ENV['RELEASE_TAG'] || ENV['TRAVIS_BRANCH'] == 'master' ? ci : "#{ENV['TRAVIS_BRANCH']}-#{ci}"; system "if git fetch origin #{ci_branch}:#{ci_branch} 2>/dev/null; then if [ #{scan} ] || [ #{/Scan/ !~ ci} ]; then git rebase #{baseline} #{ci_branch} && git push -qf -u origin #{ci_branch} >/dev/null 2>&1; fi; elif [ #{rebase} ]; then git checkout -b #{ci_branch} #{ENV['TRAVIS_BRANCH']} && rm .travis.yml && wget -q https://raw.githubusercontent.com/#{ENV['TRAVIS_REPO_SLUG']}/#{ci}/.travis.yml && git add -A . && git commit -m 'For Travis CI - switch CI build to use #{ci.split('-').first} build environment.' && git push -qf -u origin #{ci_branch} >/dev/null 2>&1; fi" or abort "Failed to rebase #{ci_branch} mirror branch" }
 end
 end
 
 
 # Usage: NOT intended to be used manually (if you insist then try: rake ci_package_upload)
 # Usage: NOT intended to be used manually (if you insist then try: rake ci_package_upload)