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

Fixed git args duplication #13411

Merged
merged 1 commit into from Nov 3, 2020
Merged

Conversation

POPSuL
Copy link
Contributor

@POPSuL POPSuL commented Nov 3, 2020

Because newGit() invoked twice (inside PreInstallInit() and GlobalInit()) and git parameters is global object, all git commands call with duplicated args -c credential.helper= -c protocol.version=2

Because newGit() invoked twice (inside PreInstallInit() and
GlobalInit()) and git parameters is global object, all
git commands call with duplicated args
`-c credential.helper= -c protocol.version=2`
Copy link
Contributor

@zeripath zeripath left a comment

Choose a reason for hiding this comment

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

damn Sorry I missed this.

@GiteaBot GiteaBot added the lgtm/need 1 This PR needs approval from one additional maintainer to be merged. label Nov 3, 2020
@zeripath zeripath added this to the 1.14.0 milestone Nov 3, 2020
@codecov-io
Copy link

Codecov Report

Merging #13411 into master will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #13411      +/-   ##
==========================================
+ Coverage   42.12%   42.13%   +0.01%     
==========================================
  Files         691      691              
  Lines       76002    76003       +1     
==========================================
+ Hits        32017    32027      +10     
+ Misses      38738    38728      -10     
- Partials     5247     5248       +1     
Impacted Files Coverage Δ
modules/setting/git.go 68.42% <100.00%> (+1.75%) ⬆️
modules/indexer/stats/db.go 52.17% <0.00%> (-8.70%) ⬇️
modules/git/utils.go 73.77% <0.00%> (-3.28%) ⬇️
modules/git/repo.go 46.19% <0.00%> (-0.51%) ⬇️
modules/queue/workerpool.go 60.00% <0.00%> (+1.22%) ⬆️
services/pull/patch.go 55.68% <0.00%> (+1.70%) ⬆️
services/pull/temp_repo.go 29.78% <0.00%> (+3.19%) ⬆️
services/pull/check.go 52.55% <0.00%> (+3.64%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update be880d4...5352125. Read the comment docs.

@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Nov 3, 2020
@lafriks lafriks merged commit 7d16e6d into go-gitea:master Nov 3, 2020
@POPSuL POPSuL deleted the fix/duplicate-git-args branch November 3, 2020 11:48
@lunny
Copy link
Member

lunny commented Nov 3, 2020

Shouldn't we remove the second call newGit?

@zeripath
Copy link
Contributor

zeripath commented Nov 3, 2020

It's part of setting.NewContext()

@go-gitea go-gitea locked and limited conversation to collaborators Dec 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants