From 38c77e1f2fb234a91dee76bc4e88f6bc87acd8ea Mon Sep 17 00:00:00 2001 From: chriswalz Date: Fri, 30 Oct 2020 00:35:16 -0400 Subject: [PATCH] fix: when parsing git commands internally use english (non-english compatibility) fixes #47 --- README.md | 4 ++++ cmd/git.go | 6 +++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 9616a07..1930f22 100644 --- a/README.md +++ b/README.md @@ -222,6 +222,10 @@ Thanks to [Gitless](https://gitless.com/), [git-extras](https://github.com/tj/gi - https://blog.csdn.net/a419240016/article/details/109178001 ## Changelog +v0.9 +- [X] enhancement: improve bit sync behavior including `bit sync ` +- [X] enhancement: bit sync provides a rebase option for diverged branches` +- [X] fix: enable compatibility with non-english languages v0.8 - [X] feature: checkout Pull Requests from github (requires `gh pr list` to work) - [X] enhancement: install with homebrew: `brew install bit-git` diff --git a/cmd/git.go b/cmd/git.go index 08edec1..b4ea99c 100644 --- a/cmd/git.go +++ b/cmd/git.go @@ -201,5 +201,9 @@ func tagCurrentBranch(version string) error { func execCommand(name string, arg ...string) *exec.Cmd { log.Debug().Msg(name + " " + strings.Join(arg, " ")) - return exec.Command(name, arg...) + c := exec.Command(name, arg...) + // exec commands are parsed by bit without getting printed. + // parsing assumes english + c.Env = append(c.Env, "LANG=C") + return c } \ No newline at end of file