mirror of https://github.com/go-gitea/gitea.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This follows * https://github.com/go-gitea/gitea/issues/18553 Introduce `RunWithContextString` and `RunWithContextBytes` to help the refactoring. Add related unit tests. They keep the same behavior to save stderr into err.Error() as `RunInXxx` before. Remove `RunInDirTimeoutPipeline` `RunInDirTimeoutFullPipeline` `RunInDirTimeout` `RunInDirTimeoutEnv` `RunInDirPipeline` `RunInDirFullPipeline` `RunTimeout`, `RunInDirTimeoutEnvPipeline`, `RunInDirTimeoutEnvFullPipeline`, `RunInDirTimeoutEnvFullPipelineFunc`. Then remaining `RunInDir` `RunInDirBytes` `RunInDirWithEnv` can be easily refactored in next PR with a simple search & replace: * before: `stdout, err := RunInDir(path)` * next: `stdout, _, err := RunWithContextString(&git.RunContext{Dir:path})` Other changes: 1. When `timeout <= 0`, use default. Because `timeout==0` is meaningless and could cause bugs. And now many functions becomes more simple, eg: `GitGcRepos` 9 lines to 1 line. `Fsck` 6 lines to 1 line. 2. Only set defaultCommandExecutionTimeout when the option `setting.Git.Timeout.Default > 0` |
3 years ago | |
---|---|---|
.. | ||
activity.go | 3 years ago | |
attachment.go | 3 years ago | |
blame.go | 3 years ago | |
branch.go | 3 years ago | |
cherry_pick.go | 3 years ago | |
commit.go | 3 years ago | |
compare.go | 3 years ago | |
download.go | 3 years ago | |
editor.go | 3 years ago | |
editor_test.go | 3 years ago | |
http.go | 3 years ago | |
http_test.go | 4 years ago | |
issue.go | 3 years ago | |
issue_content_history.go | 3 years ago | |
issue_dependency.go | 3 years ago | |
issue_label.go | 3 years ago | |
issue_label_test.go | 3 years ago | |
issue_lock.go | 3 years ago | |
issue_stopwatch.go | 3 years ago | |
issue_test.go | 3 years ago | |
issue_timetrack.go | 3 years ago | |
issue_watch.go | 3 years ago | |
lfs.go | 3 years ago | |
main_test.go | 3 years ago | |
middlewares.go | 3 years ago | |
migrate.go | 3 years ago | |
milestone.go | 3 years ago | |
packages.go | 3 years ago | |
patch.go | 3 years ago | |
projects.go | 3 years ago | |
projects_test.go | 3 years ago | |
pull.go | 3 years ago | |
pull_review.go | 3 years ago | |
release.go | 3 years ago | |
release_test.go | 3 years ago | |
repo.go | 3 years ago | |
search.go | 3 years ago | |
setting.go | 3 years ago | |
setting_protected_branch.go | 3 years ago | |
settings_test.go | 3 years ago | |
tag.go | 3 years ago | |
topic.go | 3 years ago | |
view.go | 3 years ago | |
webhook.go | 3 years ago | |
wiki.go | 3 years ago | |
wiki_test.go | 3 years ago |