Commit Graph

3 Commits

Author SHA1 Message Date
Lunny Xiao
3ce3c1277a refactor: make git.Push take a repository instead of a local path (#40448)
`git.Push` took a raw local path and ran the command with `WithDir`. It
now takes a `RepositoryFacade` and uses `WithRepo`, like the other
repository commands, and `PushFromLocal` wraps its path with
`gitrepo.RepositoryUnmanaged`.

Unmanaged repositories resolve relative paths under the repository root,
so a relative `APP_TEMP_PATH` is now made absolute at load. It already
broke repository auto-init and would otherwise also break wiki and file
edit pushes. No other behavior change.

Assisted-by: Codet:claude
Assisted-by: Claude Code:claude-opus-5-5

---------

Co-authored-by: silverwind <me@silverwind.io>
2026-11-25 00:18:50 +00:00
wxiaoguang
1acf93d854 refactor: clean up git repo and model migration packages (#38564)
enable the golangci depguard lint rule: deny "models" and its sub
packages in "modelmigration" package.
2026-07-23 01:22:26 +00:00
wxiaoguang
9dc04289aa refactor: make git package handle all git operations (#38543)
before: gitrepo vs git packages
after: git package fully handle all git operations

by the way, use `WithRepo(repo)` instead of `WithDir(repo.Path)` to hide
path details.

benefits:

1. remove all unnecessary wrappers, developers no need to struggle with
"which package should be used"
2. simplify code, RepositoryFacade can (will) be used everywhere, all
"path" details are (will be) hidden
2026-07-20 16:07:38 +00:00