Skip to content

Commit 554aabd

Browse files
committed
Fix github release errors in fastlane
1 parent 36fae6d commit 554aabd

File tree

2 files changed

+11
-9
lines changed

2 files changed

+11
-9
lines changed

Changelog.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Fixed issues:
44

55
- Fix for using CR + LF in localized strings (by @tomlokhorst)
66

7-
## 2.2.0 (beta 1)
7+
## 2.2.0
88

99
New features:
1010
- Localized string support (by @renrawnalon and @tomlokhorst)

fastlane/Fastfile

+10-8
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ lane :release do |options|
5555
changelog = prompt(text: "Please provide release notes:".green, boolean: false, ci_input: "", multi_line_end_keyword: "FIN")
5656

5757
af_insert_text_into_file(
58-
file_path: 'Changelog.md',
58+
file_path: "Changelog.md",
5959
text: "## #{newVersion}\n\n#{changelog}\n\n",
6060
insert_at_bottom: false
6161
)
@@ -64,20 +64,22 @@ lane :release do |options|
6464
raise "Aborted by user".red
6565
end
6666

67-
git_commit(
68-
path: ".",
69-
message: "Preparing for the #{newVersion} release"
70-
)
67+
unless `git status --porcelain`.empty?
68+
git_commit(
69+
path: ".",
70+
message: "Preparing for the #{newVersion} release"
71+
)
72+
end
7173

7274
push_to_git_remote
7375

7476
af_create_github_release(
7577
owner: 'mac-cain13',
7678
repository: 'r.swift',
77-
tag_name: 'v#{newVersion}',
79+
tag_name: "v#{newVersion}",
7880
target_commitish: 'master',
79-
name: '#{newVersion}',
80-
body: '#{changelog}',
81+
name: "#{newVersion}",
82+
body: "#{changelog}",
8183
prerelease: isPrerelease
8284
)
8385

0 commit comments

Comments
 (0)