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

Add command options and pass stdin to command #74

Merged
merged 4 commits into from
Apr 1, 2022

Conversation

aymanbagabas
Copy link
Contributor

  • Fix "signed shift count 4 (untyped int constant) requires go1.13 or later" compiler warning by updating go.mod go version to 1.13
  • Add the ability to pass extra envs and args to commands
  • Pass stdin to RunInDirWithPipelineTimeout

Passing stdin to RunInDirWithPipelineTimeout is useful when using Git server over ssh for example https://github.com/charmbracelet/wish/blob/0e458e40c040539ab25d5ba82859179091746648/git/git.go#L193-L202

@unknwon unknwon self-requested a review March 31, 2022 03:07
Copy link
Member

@unknwon unknwon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! Please see inline comments.

command.go Show resolved Hide resolved
repo.go Outdated Show resolved Hide resolved
repo.go Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Mar 31, 2022

Codecov Report

Merging #74 (c191002) into master (5db3510) will decrease coverage by 0.17%.
The diff coverage is 84.08%.

@@            Coverage Diff             @@
##           master      #74      +/-   ##
==========================================
- Coverage   83.56%   83.39%   -0.18%     
==========================================
  Files          24       26       +2     
  Lines        1996     1704     -292     
==========================================
- Hits         1668     1421     -247     
+ Misses        236      177      -59     
- Partials       92      106      +14     
Impacted Files Coverage Δ
blob.go 71.42% <ø> (-5.50%) ⬇️
commit.go 89.13% <ø> (-1.54%) ⬇️
hook.go 66.66% <ø> (-7.02%) ⬇️
repo_hook.go 81.25% <ø> (-1.25%) ⬇️
sha1.go 93.33% <ø> (+0.31%) ⬆️
signature.go 78.94% <ø> (+2.94%) ⬆️
tree_entry.go 74.72% <ø> (-0.66%) ⬇️
blame.go 33.33% <33.33%> (ø)
repo_reference.go 87.65% <62.50%> (-3.42%) ⬇️
repo_remote.go 77.51% <67.05%> (-21.06%) ⬇️
... and 36 more

Copy link
Member

@unknwon unknwon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thank you!

command.go Outdated Show resolved Hide resolved
@unknwon unknwon merged commit 14e6573 into gogs:master Apr 1, 2022
@unknwon
Copy link
Member

unknwon commented Apr 1, 2022

https://github.com/gogs/git-module/releases/tag/v1.6.0 has been tagged for this merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants