diff --git a/lib/git_reflow.rb b/lib/git_reflow.rb index 09f9ed4..670c83d 100644 --- a/lib/git_reflow.rb +++ b/lib/git_reflow.rb @@ -77,7 +77,7 @@ def deliver(options = {}) open_comment_authors = find_authors_of_open_pull_request_comments(existing_pull_request) # if there any comment_authors left, then they haven't given a lgtm after the last commit - if open_comment_authors.empty? + if open_comment_authors.empty? or options['skip-lgtm'] lgtm_authors = comment_authors_for_pull_request(existing_pull_request, :with => LGTM) commit_message = get_first_commit_message puts "Merging pull request ##{existing_pull_request.number}: '#{existing_pull_request.title}', from '#{existing_pull_request.head.label}' into '#{existing_pull_request.base.label}'" diff --git a/lib/git_reflow/commands/deliver.rb b/lib/git_reflow/commands/deliver.rb index 352716f..a7385e4 100644 --- a/lib/git_reflow/commands/deliver.rb +++ b/lib/git_reflow/commands/deliver.rb @@ -2,6 +2,8 @@ long_desc 'merge your feature branch down to your base branch, and cleanup your feature branch' command :deliver do |c| + c.desc 'skip the lgtm checks and deliver your feature branch' + c.switch [:f, :'skip-lgtm'] c.desc 'merge your feature branch down to your base branch, and cleanup your feature branch' c.arg_name 'base_branch - the branch you want to merge into' c.action do |global_options,options,args| @@ -13,6 +15,7 @@ when 1 deliver_options['base'] = args[0] end + deliver_options.merge({'skip_lgtm' => options[:'skip-lgtm']}) GitReflow.deliver deliver_options end end