Skip to content

Commit

Permalink
Disable git terminal prompt when detecting remote HEAD branch.
Browse files Browse the repository at this point in the history
  • Loading branch information
fredrikekre committed Apr 12, 2022
1 parent 9d96d4e commit 75f4e21
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]
### Fixed
- Disable git terminal prompt when detecting remote HEAD branch. ([#194][github-194])

## [2.13.0] - 2022-02-18
### Changed
Expand Down Expand Up @@ -196,6 +198,7 @@ https://discourse.julialang.org/t/ann-literate-jl/10651 for release announcement
[github-187]: https://github.com/fredrikekre/Literate.jl/pull/187
[github-188]: https://github.com/fredrikekre/Literate.jl/pull/188
[github-190]: https://github.com/fredrikekre/Literate.jl/pull/190
[github-194]: https://github.com/fredrikekre/Literate.jl/pull/194

[Unreleased]: https://github.com/fredrikekre/Literate.jl/compare/v2.13.0...HEAD
[2.13.0]: https://github.com/fredrikekre/Literate.jl/compare/v2.12.1...v2.13.0
Expand Down
2 changes: 1 addition & 1 deletion src/Literate.jl
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ function create_configuration(inputfile; user_config, user_kwargs, type=nothing)
if (git = Sys.which("git"); git !== nothing)
try
str = read(pipeline(ignorestatus(
setenv(`$(git) remote show origin`; dir=dirname(inputfile))
setenv(`$(git) remote show origin`, ["GIT_TERMINAL_PROMPT=0"]; dir=dirname(inputfile))
), stderr=devnull), String)
if (m = match(r"^\s*HEAD branch:\s*(.*)$"m, str); m !== nothing)
fallback_edit_commit = String(m[1])
Expand Down

0 comments on commit 75f4e21

Please sign in to comment.