Strip remote credentials without deleting remotes

This commit is contained in:
mpabi
2026-04-27 19:59:45 +02:00
parent e60b7c9148
commit ffd12c9905
4 changed files with 31 additions and 18 deletions
+5 -3
View File
@@ -437,15 +437,17 @@ Przyklad:
## `tokens remove store|remote|both REMOTE_ID`
Usuwa rekord z `tokens.json`, git remote albo oba miejsca.
Usuwa rekord z `tokens.json`, poswiadczenia z URL-a git remota albo oba
miejsca. `tokens remove remote` zostawia sam git remote, ale zapisuje jego URL
bez `LOGIN:TOKEN@`.
Domyslnym repo dla `remote` i `both` jest repo, w ktorym lezy `rvctl`. Inne
repo mozna wskazac przez `--repo PATH`.
Przelaczniki:
- `--repo PATH`
Repo, z ktorego ma byc usuniety git remote. Domyslnie repo zawierajace
`rvctl`.
Repo, w ktorym ma byc wyczyszczony URL git remota. Domyslnie repo
zawierajace `rvctl`.
- `--server ENDPOINT`
Endpoint serwera, jesli `tokens.json` ma kilka rekordow o tym samym `id`.
- `--dry-run`
+3 -1
View File
@@ -29,7 +29,9 @@ Kierunek jest jawny:
- `tokens sync remote r1` czyta git remote `r1` i zapisuje rekord do `tokens.json`
- `tokens sync store r1` czyta `tokens.json` i zapisuje auth do git remote `r1`
- `tokens update r1` nie synchronizuje sekretu, tylko pobiera metadane z API
- `tokens remove ... r1` usuwa rekord ze store, git remote albo oba miejsca
- `tokens remove store r1` usuwa rekord z `tokens.json`
- `tokens remove remote r1` usuwa poswiadczenia z URL-a git remota, ale zostawia remote
- `tokens remove both r1` usuwa rekord ze store i poswiadczenia z URL-a git remota
## Format `tokens.json`