File tree Expand file tree Collapse file tree 2 files changed +43
-5
lines changed Expand file tree Collapse file tree 2 files changed +43
-5
lines changed Original file line number Diff line number Diff line change 1+ name : Create releases
2+ on :
3+ schedule :
4+ - cron : ' 0 5 * * *' # every day at 5am UTC
5+ push :
6+ branches :
7+ - main
8+
9+ jobs :
10+ release :
11+ name : release
12+ if : github.ref == 'refs/heads/main' && github.repository == 'openai/openai-ruby'
13+ runs-on : ubuntu-latest
14+ environment : publish
15+ permissions :
16+ contents : read
17+ id-token : write
18+
19+ steps :
20+ - uses : actions/checkout@v4
21+
22+ - uses : stainless-api/trigger-release-please@v1
23+ id : release
24+ with :
25+ repo : ${{ github.event.repository.full_name }}
26+ stainless-api-key : ${{ secrets.STAINLESS_API_KEY }}
27+
28+ - name : Set up Ruby
29+ uses : ruby/setup-ruby@v1
30+ with :
31+ bundler-cache : false
32+ ruby-version : ' 3.1'
33+ - run : |-
34+ bundle install
35+
36+ - name : Publish to RubyGems.org
37+ run : |
38+ bash ./bin/publish-gem
39+ env :
40+ # `RUBYGEMS_HOST` is only required for private gem repositories, not https://rubygems.org
41+ RUBYGEMS_HOST : ${{ secrets.OPENAI_RUBYGEMS_HOST || secrets.RUBYGEMS_HOST }}
42+ GEM_HOST_API_KEY : ${{ secrets.OPENAI_GEM_HOST_API_KEY || secrets.GEM_HOST_API_KEY }}
Original file line number Diff line number Diff line change 1- # This workflow is triggered when a GitHub release is created.
2- # It can also be run manually to re-publish to rubygems.org in case it failed for some reason.
1+ # Workflow for re-publishing to rubygems.org in case it failed for some reason.
32# You can run this workflow by navigating to https://www.github.com/openai/openai-python/actions/workflows/publish-gem.yml
43name : Publish Gem
54on :
65 workflow_dispatch :
76
8- release :
9- types : [published]
10-
117jobs :
128 publish :
139 name : publish
You can’t perform that action at this time.
0 commit comments