Skip to content

Commit

Permalink
refactor git tag step
Browse files Browse the repository at this point in the history
  • Loading branch information
jyu115 committed Jan 5, 2024
1 parent 6f95d2e commit 61ab702
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/ios-sdk-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ jobs:
- name: create xcframeworks and zip
run: bundle exec fastlane ios build_xcframework output_dir:./output_dir

- name: create and push git tag
run: bundle exec fastlane ios create_git_tag version:$VERSION

- name: create github release and upload assets
run: |
bundle exec fastlane ios create_release version:$VERSION branch:$BRANCH changelog_section:$CHANGELOG_SECTION output_dir:$OUTPUT_DIR github_token:$GITHUB_TOKEN set_prerelease:$SET_PRERELEASE
Expand Down
11 changes: 9 additions & 2 deletions fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ platform :ios do
bump_release_version(version:set_version)
clean_and_lint
build_xcframework(output_dir:set_output_dir)
create_git_tag(version:set_version)
create_release(version:set_version, output_dir:set_output_dir, changelog_section:set_changelog_section, github_token:set_github_token)
pod_trunk_push
end
Expand Down Expand Up @@ -77,6 +78,14 @@ platform :ios do
)
end

desc "create git tag and push tag"
lane :create_git_tag do |options|
version = options[:version]

add_git_tag(tag: "#{version}")
push_git_tags
end

desc "create github release and upload assets"
lane :create_release do |options|
version = options[:version]
Expand All @@ -86,8 +95,6 @@ platform :ios do
github_token = options[:github_token]
set_prerelease = options[:set_prerelease]

add_git_tag(tag: "#{version}")

version_changelog = read_changelog(
changelog_path: 'CHANGELOG.md',
section_identifier: "[#{changelog_section}]",
Expand Down

0 comments on commit 61ab702

Please sign in to comment.