mirror of
https://github.com/xonsh/xonsh.git
synced 2025-03-04 08:24:40 +01:00
fix: remove os.path.basename from _get_git_branch() (#4783)
This commit is contained in:
parent
73a880f76a
commit
22cb921686
2 changed files with 24 additions and 1 deletions
23
news/fix-git-branch-name.rst
Normal file
23
news/fix-git-branch-name.rst
Normal file
|
@ -0,0 +1,23 @@
|
|||
**Added:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Changed:**
|
||||
|
||||
* fix: remove os.path.basename from _get_git_branch()
|
||||
|
||||
**Deprecated:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Removed:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Fixed:**
|
||||
|
||||
* <news item>
|
||||
|
||||
**Security:**
|
||||
|
||||
* <news item>
|
|
@ -37,7 +37,7 @@ def _get_git_branch(q):
|
|||
with contextlib.suppress(subprocess.CalledProcessError, OSError):
|
||||
branch = xt.decode_bytes(_run_git_cmd(cmds.split()))
|
||||
if branch:
|
||||
q.put(os.path.basename(branch.splitlines()[0]))
|
||||
q.put(branch.splitlines()[0])
|
||||
return
|
||||
# all failed
|
||||
q.put(None)
|
||||
|
|
Loading…
Add table
Reference in a new issue