-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: action添加cocoapods beta的手动发布workflow
- Loading branch information
Showing
3 changed files
with
36 additions
and
2 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
.github/workflows/publish.yml → .github/workflows/cocoapods.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: Publish Cocoapods | ||
name: Cocoapods | ||
on: | ||
release: | ||
types: [published] | ||
|
2 changes: 1 addition & 1 deletion
2
.github/workflows/publish_beta.yml → .github/workflows/cocoapods_beta.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# This is a basic workflow to help you get started with Actions | ||
|
||
name: Cocoapods beta Manual | ||
|
||
# Controls when the action will run. Triggers the workflow on push or pull request | ||
# events but only for the master branch | ||
on: workflow_dispatch | ||
|
||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel | ||
jobs: | ||
# This workflow contains a single job called "build" | ||
build: | ||
# The type of runner that the job will run on | ||
runs-on: macos-latest | ||
# main 分支的发布请走正式流程,手动仅能发布其他分支的beta版本,用于测试 | ||
if: ${{ github.ref != 'refs/heads/master' }} | ||
# Steps represent a sequence of tasks that will be executed as part of the job | ||
steps: | ||
- name: Install Cocoapods | ||
run: gem install cocoapods | ||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Create CocoaPods beta | ||
run: | | ||
set -eo pipefail | ||
pod repo update | ||
chmod +x Scripts/cocoapods-beta.sh | ||
sh Scripts/cocoapods-beta.sh | ||
env: | ||
COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.REPO_TOKEN }} |