Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport multibyte commit message fix to Pharo 11 #1877

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Iceberg-Libgit/IceGitIndex.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ IceGitIndex >> commitWithMessage: message andParents: parentCommits [
index free.
commitId := (LGitCommitBuilder of: self repositoryHandle)
tree: (LGitTree of: self repositoryHandle fromId: indexTreeId);
message: message withUnixLineEndings utf8Encoded asString "FFI is expecting an string";
message: message withUnixLineEndings "FFI is expecting an string";
parents:
(self repositoryHandle isUnborn
ifTrue: [ #() ]
Expand Down
9 changes: 9 additions & 0 deletions Iceberg-Tests/IceGitCommitMessageTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,15 @@ IceGitCommitMessageTest >> testCommitNullString [

]

{ #category : #tests }
IceGitCommitMessageTest >> testCommitWideString [
| msg |
msg := ZnUTF8Encoder new decodeBytes: (ByteArray readHexFrom: 'e38182e38184e38186'). "Japanese vowels a,i, and u - 'あいう'"
self repository commitWithMessage: msg.
self assert: self repository head commit comment equals: msg.

]

{ #category : #tests }
IceGitCommitMessageTest >> testCommitWithEndingPesosSign [
"We used to have a problem that in some messages (depending of padding) the $ was added at the end"
Expand Down
Loading