From 1452a0c7af2cc89dd43f027036b8bca80468f7b5 Mon Sep 17 00:00:00 2001 From: Dan Bode Date: Tue, 26 Feb 2013 23:18:25 -0800 Subject: [PATCH] Allow trusted user to schedule pull requests for testing Currently, the github:checout_pull_request job requires that the trusted admin who can verify which pull requests should be tested can only be the same as the user used for authentication. This commits adds a seperate key to the github_auth file that can be used to set a seperate admin --- Rakefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Rakefile b/Rakefile index 72aed3b..64a930f 100644 --- a/Rakefile +++ b/Rakefile @@ -15,6 +15,10 @@ def github_password YAML.load_file(File.join(base_dir, '.github_auth'))['password'] end +def github_admins + YAML.load_file(File.join(base_dir, '.github_auth'))['admins'].to_a +end + def github_login YAML.load_file(File.join(base_dir, '.github_auth'))['login'] end @@ -129,7 +133,7 @@ namespace :github do checkout_pr( args.project_name, args.number, - [github_login], + [github_login] + github_admins 'schedule_for_testing', { :login => github_login,