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

Remove Unused Functions #10516

Merged
merged 21 commits into from
Mar 1, 2020
Merged

Remove Unused Functions #10516

merged 21 commits into from
Mar 1, 2020

Conversation

6543
Copy link
Member

@6543 6543 commented Feb 27, 2020

each commit is one related remove ... so feel free to point to a specific commit hash to revert ...

It is a huge imprvement for the modules/structs package ;) since it should not contain any function ...

@6543
Copy link
Member Author

6543 commented Feb 27, 2020

-------------------------------------- space ----------------------------------------------

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Feb 27, 2020
@sapk
Copy link
Member

sapk commented Feb 27, 2020

Removing code is the best change.
I am curious of how you discover thoses unused functions ?

@sapk sapk added the type/refactoring Existing code has been cleaned up. There should be no new functionality. label Feb 27, 2020
@sapk sapk added this to the 1.12.0 milestone Feb 27, 2020
@6543
Copy link
Member Author

6543 commented Feb 27, 2020

@sapk via golands "code inspection" and a lot of recusrive grep + time to look throu the code
ps: the code inspection suggested a lot more but I wasn't aggressiv with removing stuff (somebody may use this or that func in the future ...) but I found some nice things :D (#10513 was also based on this)

@sapk
Copy link
Member

sapk commented Feb 27, 2020

@6543 Ok, it looks good at first glance. For code part you hesitate we could use the Deprecated: syntax to highlight part that need to be cleaned later. But that already a good batch. Thanks for the time taken.

@codecov-io
Copy link

codecov-io commented Feb 28, 2020

Codecov Report

Merging #10516 into master will decrease coverage by 0.04%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #10516      +/-   ##
==========================================
- Coverage   43.86%   43.82%   -0.05%     
==========================================
  Files         584      584              
  Lines       81649    81649              
==========================================
- Hits        35815    35782      -33     
- Misses      41399    41430      +31     
- Partials     4435     4437       +2
Impacted Files Coverage Δ
routers/repo/webhook.go 1.27% <0%> (ø) ⬆️
models/repo_mirror.go 2.12% <0%> (-10.64%) ⬇️
services/pull/check.go 50% <0%> (-5.49%) ⬇️
modules/git/utils.go 65.67% <0%> (-4.48%) ⬇️
modules/git/command.go 86.95% <0%> (-2.61%) ⬇️
services/pull/patch.go 61.93% <0%> (-2.59%) ⬇️
services/pull/temp_repo.go 29.05% <0%> (-2.57%) ⬇️
modules/queue/unique_queue_disk_channel.go 53.84% <0%> (-1.93%) ⬇️
modules/queue/workerpool.go 56.93% <0%> (-1.07%) ⬇️
modules/git/repo.go 46.78% <0%> (-0.92%) ⬇️
... and 5 more

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 89eabbe...e8d23fa. Read the comment docs.

@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Feb 29, 2020
@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 Feb 29, 2020
@lafriks lafriks added the skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. label Feb 29, 2020
@lafriks lafriks merged commit 4160bd6 into go-gitea:master Mar 1, 2020
@6543 6543 deleted the remove-unused branch March 2, 2020 12:25
@go-gitea go-gitea locked and limited conversation to collaborators Nov 24, 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. skip-changelog This PR is irrelevant for the (next) changelog, for example bug fixes for unreleased features. type/refactoring Existing code has been cleaned up. There should be no new functionality.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants