Commit graph

3 commits

Author SHA1 Message Date
0d06d5cb89
refactor(credentials): add cp.Credentials LuaCATS class 2026-03-07 19:50:34 -05:00
5aa2c024e0
feat(credentials): guard login/submit/logout on credential helper
Problem: if no git credential helper is configured, login and
submit silently fail to persist credentials.

Solution: add `has_helper()` to `git_credential.lua` that checks
`git config credential.helper`. Guard the top of `login()`,
`logout()`, and `submit()` with an early-return error. Add a
healthcheck warning when no helper is configured. Add LuaCATS
annotations to all `git_credential` functions.
2026-03-07 19:50:04 -05:00
72c72fbc41
feat(credentials): add git_credential module
Problem: credentials were stored as plaintext JSON in the cache
file, with no integration with system credential managers.

Solution: add `lua/cp/git_credential.lua` wrapping the
`git credential fill/approve/reject` protocol. Maps each platform
to its host, handles CSES token as a second entry with
`path=api-token`.
2026-03-07 19:46:22 -05:00