use Gemfile

This commit is contained in:
miguemasx 2019-11-26 19:06:53 +01:00
parent 4838aa3d8c
commit ebc60ce775
10 changed files with 34 additions and 6 deletions

3
.dockerignore Normal file
View File

@ -0,0 +1,3 @@
spec
fixtures
screenshots

View File

@ -1,7 +1,8 @@
FROM ruby:2.6.3-alpine
RUN gem install octokit
WORKDIR /action
COPY Gemfile Gemfile.lock /action/
RUN bundle install
COPY lib /action/lib
CMD ["ruby", "/action/lib/index.rb"]

2
Gemfile Normal file
View File

@ -0,0 +1,2 @@
source 'https://rubygems.org'
gem 'octokit'

22
Gemfile.lock Normal file
View File

@ -0,0 +1,22 @@
GEM
specs:
addressable (2.7.0)
public_suffix (>= 2.0.2, < 5.0)
faraday (0.17.0)
multipart-post (>= 1.2, < 3)
multipart-post (2.1.1)
octokit (4.14.0)
sawyer (~> 0.8.0, >= 0.5.3)
public_suffix (4.0.1)
sawyer (0.8.2)
addressable (>= 2.3.5)
faraday (> 0.8, < 2.0)
PLATFORMS
ruby
DEPENDENCIES
octokit
BUNDLED WITH
1.17.2

View File

@ -1,6 +1,6 @@
require 'json'
require 'octokit'
require_relative './merge_branch_service'
require_relative './services/merge_branch_service'
@event = JSON.parse(File.read(ENV['GITHUB_EVENT_PATH']))
@head_to_merge = ENV['GITHUB_SHA'] # or brach name

View File

@ -1,5 +1,5 @@
require_relative './labeled_adapter'
require_relative './push_adapter'
require_relative '../adapters/labeled_adapter'
require_relative '../adapters/push_adapter'
class MergeBrachService

View File

@ -1,4 +1,4 @@
require_relative '../lib/merge_branch_service'
require_relative '../lib/services/merge_branch_service'
describe MergeBrachService do
context "with push" do