File tree 1 file changed +66
-0
lines changed
1 file changed +66
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : release
2
+ on :
3
+ push :
4
+ tags :
5
+ - " *"
6
+ jobs :
7
+ build :
8
+ runs-on : ubuntu-latest
9
+ steps :
10
+ - name : Checkout repository
11
+ uses : actions/checkout@v1
12
+
13
+ - name : Get deps cache
14
+ uses : actions/cache@v1
15
+ with :
16
+ path : vendor/bundle
17
+ key : ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
18
+ restore-keys : ${{ runner.os }}-gems-
19
+
20
+ - uses : actions/setup-ruby@v1
21
+ with :
22
+ ruby-version : " 2.6"
23
+
24
+ - name : Bundle install
25
+ run : |
26
+ gem install bundler:2.1.4
27
+ bundle config path vendor/bundle
28
+ bundle install --jobs 4 --retry 3
29
+
30
+ - name : Build docset
31
+ run : |
32
+ bundle exec cheatset generate terraform.rb
33
+ zip terraform-docset.zip Terraform.docset
34
+
35
+ - uses : actions/upload-artifact@v2
36
+ with :
37
+ name : terraform-docset
38
+ path : terraform-docset.zip
39
+
40
+ release :
41
+ needs : build
42
+ runs-on : ubuntu-latest
43
+ steps :
44
+ - name : Download artifact
45
+ uses : actions/download-artifact@v2
46
+ with :
47
+ name : terraform-docset
48
+ - name : Create release
49
+ id : create_release
50
+ uses : actions/create-release@v1
51
+ env :
52
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
53
+ with :
54
+ tag_name : ${{ github.ref }}
55
+ release_name : Release ${{ github.ref }}
56
+ draft : false
57
+ prerelease : false
58
+ - name : Upload Release Asset
59
+ uses : actions/upload-release-asset@v1
60
+ env :
61
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
62
+ with :
63
+ upload_url : ${{ steps.create_release.outputs.upload_url }}
64
+ asset_path : ./terraform-docset.zip
65
+ asset_name : terraform-docset.zip
66
+ asset_content_type : application/zip
You can’t perform that action at this time.
0 commit comments