File tree Expand file tree Collapse file tree 2 files changed +57
-26
lines changed Expand file tree Collapse file tree 2 files changed +57
-26
lines changed Original file line number Diff line number Diff line change
1
+ name : ci
2
+
3
+ on : [push]
4
+
5
+ jobs :
6
+ compile :
7
+ runs-on : ubuntu-latest
8
+
9
+ steps :
10
+ - name : Checkout repo
11
+ uses : actions/checkout@v4
12
+
13
+ - name : Set up Ruby
14
+ uses : ruby/setup-ruby@v1
15
+ with :
16
+ ruby-version : ' 2.7'
17
+
18
+ - name : Build gem
19
+ run : gem build merge_ruby_client.gemspec
20
+
21
+ test :
22
+ runs-on : ubuntu-latest
23
+
24
+ steps :
25
+ - name : Checkout repo
26
+ uses : actions/checkout@v4
27
+
28
+ - name : Set up Ruby
29
+ uses : ruby/setup-ruby@v1
30
+ with :
31
+ ruby-version : ' 2.7'
32
+
33
+ - name : Run tests
34
+ run : bundle install && bundle exec rake test
35
+
36
+ publish :
37
+ needs : [ compile, test ]
38
+ if : github.event_name == 'push' && contains(github.ref, 'refs/tags/')
39
+ runs-on : ubuntu-latest
40
+ steps :
41
+ - name : Checkout repo
42
+ uses : actions/checkout@v3
43
+
44
+ - uses : ruby/setup-ruby@v1
45
+ with :
46
+ ruby-version : 2.7
47
+ bundler-cache : true
48
+
49
+ - name : Test gem
50
+ run : bundle install && bundle exec rake test
51
+
52
+ - name : Build and Push Gem
53
+ env :
54
+ GEM_HOST_API_KEY : ${{ secrets.RUBY_GEMS_API_KEY }}
55
+ run : |
56
+ gem build merge_ruby_client.gemspec
57
+ gem push merge_ruby_client-*.gem --host https://rubygems.org/
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments