@cat-indev/catops-cli 0.0.1-alpha.40 → 0.0.1-alpha.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +165 -0
- package/dist/services/git.d.ts +327 -8
- package/dist/services/git.js +517 -17
- package/dist/services/git.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -424,6 +424,171 @@ await ctx.services.docker.validateSpace({ images: 8 * 1e9 }, undefined, true);
|
|
|
424
424
|
|
|
425
425
|
Los umbrales y los tamaños del `systemDf` se expresan en **bytes** (con `parseSize` que normaliza `KB/MB/GB/TB`). Todas las funciones aceptan `exec` (retry/timeout/dryRun) como antes.
|
|
426
426
|
|
|
427
|
+
## Git (`ctx.services.git`)
|
|
428
|
+
|
|
429
|
+
`ctx.services.git` cubre el flujo completo de trabajo con git: `clone`, `checkout`, creación/borrado/listado de **ramas**, `pull`/`fetch`, `add`/`commit`/`push`, `tag`, `merge`/`rebase`, `status`/`log`/`diff`/`show`, `remote`, `stash`, `reset`, `init`, `config` y `revParse`.
|
|
430
|
+
|
|
431
|
+
Todas las funciones aceptan `exec` (retry/timeout/dryRun) como último argumento plano (`git.push({ retry: 3 })`) o embebido en el objeto de opciones (`git.commit({ exec: { retry: 3 } })`).
|
|
432
|
+
|
|
433
|
+
```javascript
|
|
434
|
+
// clone — con rama y profundidad opcionales
|
|
435
|
+
await ctx.services.git.clone("https://github.com/org/repo.git", "./repo");
|
|
436
|
+
await ctx.services.git.clone("https://github.com/org/repo.git", "./repo", {
|
|
437
|
+
branch: "dev", depth: 1, singleBranch: true
|
|
438
|
+
});
|
|
439
|
+
|
|
440
|
+
// checkout — pasarse de rama, o crearla y pasarse
|
|
441
|
+
await ctx.services.git.checkout("develop");
|
|
442
|
+
await ctx.services.git.checkout("feat/api", { create: true }); // git checkout -b feat/api
|
|
443
|
+
await ctx.services.git.checkout("dev", { create: true, track: true, startPoint: "origin/dev" });
|
|
444
|
+
```
|
|
445
|
+
|
|
446
|
+
**Ramas** — `branch` (genérico) y helpers dedicados `branchCreate`, `branchDelete`, `branchRename`, `branchList`, `branchShowCurrent`, `branchSetUpstream`, `branchUnsetUpstream`:
|
|
447
|
+
|
|
448
|
+
```javascript
|
|
449
|
+
// Crear
|
|
450
|
+
await ctx.services.git.branchCreate("feat/x", { startPoint: "main" });
|
|
451
|
+
await ctx.services.git.branchCreate("feat/x", { startPoint: "origin/main", track: true });
|
|
452
|
+
await ctx.services.git.branchCreate("hotfix", { force: true }); // git branch -f hotfix
|
|
453
|
+
|
|
454
|
+
// Borrar (con -D si usás force) y renombrar
|
|
455
|
+
await ctx.services.git.branchDelete("feat/x");
|
|
456
|
+
await ctx.services.git.branchDelete("legacy", { force: true }); // git branch -D legacy
|
|
457
|
+
await ctx.services.git.branchRename("feature/x"); // renombra la rama actual
|
|
458
|
+
await ctx.services.git.branchRename("feature/x", { oldName: "feat/x" });
|
|
459
|
+
await ctx.services.git.branchRename("feature/x", { oldName: "feat/x", force: true }); // -M
|
|
460
|
+
|
|
461
|
+
// Listar
|
|
462
|
+
await ctx.services.git.branchList({ all: true }); // git branch -a
|
|
463
|
+
await ctx.services.git.branchList({ remote: true, verbose: true }); // git branch -r -vv
|
|
464
|
+
await ctx.services.git.branchList({ merged: "main" }); // las ya fusionadas en main
|
|
465
|
+
await ctx.services.git.branchList({ noMerged: true, pattern: "feat*" });
|
|
466
|
+
await ctx.services.git.branchList({ contains: "abc123", sort: "-committerdate" });
|
|
467
|
+
|
|
468
|
+
// Actual y upstream
|
|
469
|
+
const current = await ctx.services.git.branchShowCurrent(); // git branch --show-current
|
|
470
|
+
await ctx.services.git.branchSetUpstream({ upstream: "origin/main" }); // git branch -u origin/main
|
|
471
|
+
await ctx.services.git.branchSetUpstream({ upstream: "origin/main", name: "dev" });
|
|
472
|
+
await ctx.services.git.branchUnsetUpstream(); // git branch --unset-upstream
|
|
473
|
+
```
|
|
474
|
+
|
|
475
|
+
**pull / fetch** — con remote, rama y estrategia:
|
|
476
|
+
|
|
477
|
+
```javascript
|
|
478
|
+
await ctx.services.git.pull(); // git pull
|
|
479
|
+
await ctx.services.git.pull({ remote: "origin", branch: "main", rebase: true });
|
|
480
|
+
await ctx.services.git.pull({ remote: "origin", branch: "main", ffOnly: true });
|
|
481
|
+
await ctx.services.git.pull({ prune: true, tags: true });
|
|
482
|
+
|
|
483
|
+
await ctx.services.git.fetch(); // git fetch --all (default)
|
|
484
|
+
await ctx.services.git.fetch({ remote: "origin", branch: "develop" });
|
|
485
|
+
await ctx.services.git.fetch({ depth: 1, tags: true });
|
|
486
|
+
await ctx.services.git.fetch({ prune: true });
|
|
487
|
+
```
|
|
488
|
+
|
|
489
|
+
**add / commit / push** — `add` acepta un arreglo de archivos o `"."`; `commit` hace el `add` automáticamente si le pasás archivos:
|
|
490
|
+
|
|
491
|
+
```javascript
|
|
492
|
+
// add
|
|
493
|
+
await ctx.services.git.add(".");
|
|
494
|
+
await ctx.services.git.add(["src/", "package.json"]);
|
|
495
|
+
await ctx.services.git.add(".", { all: true }); // git add -A .
|
|
496
|
+
await ctx.services.git.add(["src/"], { force: true }); // git add -f src/
|
|
497
|
+
|
|
498
|
+
// commit — si recibís archivos, los agrega solos antes de commitear
|
|
499
|
+
await ctx.services.git.commit("fix: corrección de login");
|
|
500
|
+
await ctx.services.git.commit("feat: api", ["src/api/**"], { amend: false });
|
|
501
|
+
await ctx.services.git.commit("feat: todo", { files: ".", allowEmpty: true });
|
|
502
|
+
await ctx.services.git.commit("wip", ".", { exec: { retry: 2 } });
|
|
503
|
+
await ctx.services.git.commit("release", { all: true, amend: true }); // git commit -a --amend
|
|
504
|
+
|
|
505
|
+
// push — remote y rama posicionales u opcionales
|
|
506
|
+
await ctx.services.git.push(); // git push
|
|
507
|
+
await ctx.services.git.push("origin"); // git push origin
|
|
508
|
+
await ctx.services.git.push("origin", "main"); // git push origin main
|
|
509
|
+
await ctx.services.git.push({ remote: "origin", branch: "main", setUpstream: true }); // -u
|
|
510
|
+
await ctx.services.git.push({ remote: "origin", branch: "main", force: true }); // --force
|
|
511
|
+
await ctx.services.git.push({ remote: "origin", branch: "main", forceWithLease: true });
|
|
512
|
+
await ctx.services.git.push({ tags: true }); // git push --tags
|
|
513
|
+
```
|
|
514
|
+
|
|
515
|
+
**tags**:
|
|
516
|
+
|
|
517
|
+
```javascript
|
|
518
|
+
await ctx.services.git.tag("v1.0.0"); // git tag v1.0.0
|
|
519
|
+
await ctx.services.git.tag("v1.0.0", { message: "release 1.0" }); // anotada
|
|
520
|
+
await ctx.services.git.tag("v1.0.0", { message: "release", force: true });
|
|
521
|
+
await ctx.services.git.tagDelete("v1.0.0"); // git tag -d v1.0.0
|
|
522
|
+
await ctx.services.git.tagList({ pattern: "v1.*", sort: "-creatordate" });
|
|
523
|
+
```
|
|
524
|
+
|
|
525
|
+
**merge / rebase**:
|
|
526
|
+
|
|
527
|
+
```javascript
|
|
528
|
+
await ctx.services.git.merge("develop");
|
|
529
|
+
await ctx.services.git.merge("develop", { noEdit: true });
|
|
530
|
+
await ctx.services.git.merge("main", { ffOnly: true }); // aborta si no es fast-forward
|
|
531
|
+
await ctx.services.git.merge({ abort: true }); // aborta el merge en conflicto
|
|
532
|
+
|
|
533
|
+
await ctx.services.git.rebase({ branch: "main" }); // git rebase main
|
|
534
|
+
await ctx.services.git.rebase({ branch: "dev", onto: "main" });
|
|
535
|
+
await ctx.services.git.rebase({ interactive: true });
|
|
536
|
+
await ctx.services.git.rebase({ abort: true }); // aborta el rebase en curso
|
|
537
|
+
```
|
|
538
|
+
|
|
539
|
+
**status / log / diff / show**:
|
|
540
|
+
|
|
541
|
+
```javascript
|
|
542
|
+
await ctx.services.git.status();
|
|
543
|
+
await ctx.services.git.status({ short: true, branch: true }); // git status -sb
|
|
544
|
+
await ctx.services.git.status({ porcelain: true }); // para scripting
|
|
545
|
+
|
|
546
|
+
await ctx.services.git.log({ maxCount: 10, oneline: true }); // git log --max-count 10 --oneline
|
|
547
|
+
await ctx.services.git.log({ since: "2 weeks ago", author: "miuser" });
|
|
548
|
+
await ctx.services.git.log({ graph: true, allBranches: true });
|
|
549
|
+
|
|
550
|
+
await ctx.services.git.diff({ stat: true }); // git diff --stat
|
|
551
|
+
await ctx.services.git.diff({ cached: true }); // staged
|
|
552
|
+
await ctx.services.git.diff({ nameOnly: true }); // solo archivos
|
|
553
|
+
|
|
554
|
+
await ctx.services.git.show("HEAD"); // git show HEAD
|
|
555
|
+
await ctx.services.git.show("abc123", { stat: true }); // git show --stat abc123
|
|
556
|
+
```
|
|
557
|
+
|
|
558
|
+
**remote / stash / reset / init / config / revParse**:
|
|
559
|
+
|
|
560
|
+
```javascript
|
|
561
|
+
// remote
|
|
562
|
+
await ctx.services.git.remote({ verbose: true }); // git remote -v
|
|
563
|
+
await ctx.services.git.remote({ show: "origin" }); // git remote show origin
|
|
564
|
+
await ctx.services.git.remoteAdd("upstream", "https://github.com/org/repo.git");
|
|
565
|
+
await ctx.services.git.remoteRemove("upstream");
|
|
566
|
+
await ctx.services.git.remoteSetUrl("origin", "git@github.com:org/repo.git");
|
|
567
|
+
|
|
568
|
+
// stash
|
|
569
|
+
await ctx.services.git.stashPush({ message: "wip", includeUntracked: true });
|
|
570
|
+
await ctx.services.git.stashPush({ keepIndex: true });
|
|
571
|
+
await ctx.services.git.stashList();
|
|
572
|
+
await ctx.services.git.stashPop(); // git stash pop
|
|
573
|
+
await ctx.services.git.stashPop({ index: 1 }); // git stash pop stash@{1}
|
|
574
|
+
await ctx.services.git.stashApply({ index: 0 });
|
|
575
|
+
await ctx.services.git.stashDrop({ index: 2 });
|
|
576
|
+
|
|
577
|
+
// reset / init / config
|
|
578
|
+
await ctx.services.git.reset({ mode: "hard", commit: "HEAD~1" }); // git reset --hard HEAD~1
|
|
579
|
+
await ctx.services.git.init({ initialBranch: "main" }); // git init -b main
|
|
580
|
+
await ctx.services.git.configSet("user.name", "Cat");
|
|
581
|
+
await ctx.services.git.configGet("user.name");
|
|
582
|
+
await ctx.services.git.configList();
|
|
583
|
+
|
|
584
|
+
// revParse — resuelve refs (default HEAD)
|
|
585
|
+
const sha = await ctx.services.git.revParse(); // git rev-parse HEAD
|
|
586
|
+
await ctx.services.git.revParse("HEAD~1");
|
|
587
|
+
await ctx.services.git.revParse({ short: true }); // SHA abreviado
|
|
588
|
+
await ctx.services.git.revParse({ abbrevRef: true }); // nombre de la rama actual
|
|
589
|
+
await ctx.services.git.revParse({ showTopLevel: true }); // raíz absoluta del repo
|
|
590
|
+
```
|
|
591
|
+
|
|
427
592
|
## kubectl / oc: kubeconfig, namespace, retry/timeout, y espera cíclica del rollout
|
|
428
593
|
|
|
429
594
|
`kubectl` y `oc` aceptan `{ kubeconfig, namespace, exec }` como último argumento en **todos** sus comandos (retrocompatible, sigue funcionando sin ese argumento — ver la sección anterior para el detalle de `exec`):
|
package/dist/services/git.d.ts
CHANGED
|
@@ -1,9 +1,328 @@
|
|
|
1
1
|
import type { ExecOptions, ExecResult } from "../core/types";
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export declare function
|
|
8
|
-
export
|
|
9
|
-
|
|
2
|
+
export interface GitCommon {
|
|
3
|
+
/** retry/timeout/dryRun para esta llamada puntual (ver shell.exec). */
|
|
4
|
+
exec?: ExecOptions;
|
|
5
|
+
}
|
|
6
|
+
/** True si el objeto solo contiene claves de ExecOptions (retry/timeout/dryRun/env...). */
|
|
7
|
+
export declare function isBareExec(value: unknown): value is ExecOptions;
|
|
8
|
+
export interface GitCloneOptions extends GitCommon {
|
|
9
|
+
/** `--branch <name>`: rama a clonar en lugar de la default. */
|
|
10
|
+
branch?: string;
|
|
11
|
+
/** `--depth <n>`: clon shallow con n historias. */
|
|
12
|
+
depth?: number;
|
|
13
|
+
/** `--bare`: clon sin working tree (para repos remotos de despliegue). */
|
|
14
|
+
bare?: boolean;
|
|
15
|
+
/** `--single-branch`: clona solo la rama indicada, sin las demás refs. */
|
|
16
|
+
singleBranch?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export declare function clone(url: string, targetPath: string, opts?: GitCloneOptions | ExecOptions): Promise<ExecResult>;
|
|
19
|
+
export interface GitCheckoutOptions extends GitCommon {
|
|
20
|
+
/** `-b`: crear la rama y pasarse a ella. */
|
|
21
|
+
create?: boolean;
|
|
22
|
+
/** `--track`: crear la rama con upstream hacia una remota. */
|
|
23
|
+
track?: boolean;
|
|
24
|
+
/** `-f`: descartar cambios locales en conflicto. */
|
|
25
|
+
force?: boolean;
|
|
26
|
+
/** `--detach`: dejar HEAD en detached. */
|
|
27
|
+
detach?: boolean;
|
|
28
|
+
/** Rama/commit base cuando se crea (`git checkout -b dev origin/dev`). */
|
|
29
|
+
startPoint?: string;
|
|
30
|
+
}
|
|
31
|
+
export declare function checkout(branch: string, opts?: GitCheckoutOptions | ExecOptions): Promise<ExecResult>;
|
|
32
|
+
export interface GitBranchOptions extends GitCommon {
|
|
33
|
+
/** Crea una rama: `git branch <create> [startPoint]`. */
|
|
34
|
+
create?: string;
|
|
35
|
+
/** Punto de partida al crear la rama. */
|
|
36
|
+
startPoint?: string;
|
|
37
|
+
/** `-f`: recrea/reapunta la rama existente. */
|
|
38
|
+
forceCreate?: boolean;
|
|
39
|
+
/** Borra una rama con `-d` (solo si está fusionada). */
|
|
40
|
+
delete?: string;
|
|
41
|
+
/** Borra con `-D`, ignorando estado de fusión. */
|
|
42
|
+
forceDelete?: string;
|
|
43
|
+
/** `--show-current`: imprime la rama actual. */
|
|
44
|
+
showCurrent?: boolean;
|
|
45
|
+
/** `-a`: lista también ramas remotas. */
|
|
46
|
+
all?: boolean;
|
|
47
|
+
}
|
|
48
|
+
export declare function branch(opts?: GitBranchOptions | ExecOptions): Promise<ExecResult>;
|
|
49
|
+
export interface GitBranchCreateOptions extends GitCommon {
|
|
50
|
+
/** Punto de partida al crear (`git branch <name> <startPoint>`). */
|
|
51
|
+
startPoint?: string;
|
|
52
|
+
/** `-f`: recrea/reapunta una rama existente. */
|
|
53
|
+
force?: boolean;
|
|
54
|
+
/** `--track`: deja configurado el upstream hacia `startPoint` (o el remoto). */
|
|
55
|
+
track?: boolean;
|
|
56
|
+
}
|
|
57
|
+
export declare function branchCreate(name: string, opts?: GitBranchCreateOptions | ExecOptions): Promise<ExecResult>;
|
|
58
|
+
export interface GitBranchDeleteOptions extends GitCommon {
|
|
59
|
+
/** `-D` en vez de `-d`: borra aunque la rama no esté fusionada. */
|
|
60
|
+
force?: boolean;
|
|
61
|
+
}
|
|
62
|
+
export declare function branchDelete(name: string, opts?: GitBranchDeleteOptions | ExecOptions): Promise<ExecResult>;
|
|
63
|
+
export interface GitBranchRenameOptions extends GitCommon {
|
|
64
|
+
/** Si se omite, renombra la rama actual. */
|
|
65
|
+
oldName?: string;
|
|
66
|
+
/** `-M` en vez de `-m`: renombra aunque el nuevo nombre exista. */
|
|
67
|
+
force?: boolean;
|
|
68
|
+
}
|
|
69
|
+
export declare function branchRename(newName: string, opts?: GitBranchRenameOptions | ExecOptions): Promise<ExecResult>;
|
|
70
|
+
export interface GitBranchListOptions extends GitCommon {
|
|
71
|
+
/** `-a`: ramas locales y remotas. */
|
|
72
|
+
all?: boolean;
|
|
73
|
+
/** `-r`: solo ramas remotas. */
|
|
74
|
+
remote?: boolean;
|
|
75
|
+
/** `--merged [commit]`: solo ramas ya fusionadas en commit. */
|
|
76
|
+
merged?: boolean | string;
|
|
77
|
+
/** `--no-merged [commit]`: solo ramas NO fusionadas en commit. */
|
|
78
|
+
noMerged?: boolean | string;
|
|
79
|
+
/** `--contains <commit>`: ramas que contienen el commit. */
|
|
80
|
+
contains?: string;
|
|
81
|
+
/** `-vv`: muestra SHA y upstream de cada rama. */
|
|
82
|
+
verbose?: boolean;
|
|
83
|
+
/** `--sort=<clave>` (ej. "-committerdate", "authordate"). */
|
|
84
|
+
sort?: string;
|
|
85
|
+
/** Patrón de filtro para `git branch --list <pattern>`. */
|
|
86
|
+
pattern?: string;
|
|
87
|
+
}
|
|
88
|
+
export declare function branchList(opts?: GitBranchListOptions | ExecOptions): Promise<ExecResult>;
|
|
89
|
+
export declare function branchShowCurrent(opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
90
|
+
export interface GitBranchUpstreamOptions extends GitCommon {
|
|
91
|
+
/** Upstream a asignar (ej. "origin/main"). */
|
|
92
|
+
upstream: string;
|
|
93
|
+
/** Rama a la que aplicar; si se omite, la actual. */
|
|
94
|
+
name?: string;
|
|
95
|
+
}
|
|
96
|
+
export declare function branchSetUpstream(opts?: GitBranchUpstreamOptions | ExecOptions): Promise<ExecResult>;
|
|
97
|
+
export declare function branchUnsetUpstream(name?: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
98
|
+
export interface GitPullOptions extends GitCommon {
|
|
99
|
+
/** Origin/repositorio a traer (`git pull <remote>`). */
|
|
100
|
+
remote?: string;
|
|
101
|
+
/** Rama/refspec a traer (`git pull origin main`). */
|
|
102
|
+
branch?: string;
|
|
103
|
+
/** `--rebase`: reaplica el trabajo local sobre el remoto. */
|
|
104
|
+
rebase?: boolean;
|
|
105
|
+
/** `--no-rebase`: fuerza merge en vez de rebase. */
|
|
106
|
+
noRebase?: boolean;
|
|
107
|
+
/** `--ff-only`: solo avanza si se puede hacer fast-forward. */
|
|
108
|
+
ffOnly?: boolean;
|
|
109
|
+
/** `--no-ff`: crea commit de merge aunque haya fast-forward. */
|
|
110
|
+
noFF?: boolean;
|
|
111
|
+
/** `--prune`: borra refs remotas que desaparecieron. */
|
|
112
|
+
prune?: boolean;
|
|
113
|
+
/** `--tags`: trae también las etiquetas. */
|
|
114
|
+
tags?: boolean;
|
|
115
|
+
}
|
|
116
|
+
export declare function pull(opts?: GitPullOptions | ExecOptions): Promise<ExecResult>;
|
|
117
|
+
export interface GitFetchOptions extends GitCommon {
|
|
118
|
+
/** Remote a fetchear; al indicarlo se omite `--all`. */
|
|
119
|
+
remote?: string;
|
|
120
|
+
/** Rama específica a fetchear. */
|
|
121
|
+
branch?: string;
|
|
122
|
+
/** `--depth <n>`: solo las n historias más recientes. */
|
|
123
|
+
depth?: number;
|
|
124
|
+
/** `--unshallow`: convierte un clon shallow en completo. */
|
|
125
|
+
unshallow?: boolean;
|
|
126
|
+
/** `--prune`: borra refs remotas huérfanas. */
|
|
127
|
+
prune?: boolean;
|
|
128
|
+
/** `--tags`: descarga también las etiquetas. */
|
|
129
|
+
tags?: boolean;
|
|
130
|
+
/** `--all` (default true si no se indica remote). */
|
|
131
|
+
all?: boolean;
|
|
132
|
+
}
|
|
133
|
+
export declare function fetch(opts?: GitFetchOptions | ExecOptions): Promise<ExecResult>;
|
|
134
|
+
export interface GitAddOptions extends GitCommon {
|
|
135
|
+
/** `-A`: agrega también archivos borrados/renombrados del working tree. */
|
|
136
|
+
all?: boolean;
|
|
137
|
+
/** `-u`: solo actualiza archivos ya rastreados. */
|
|
138
|
+
update?: boolean;
|
|
139
|
+
/** `-f`: agrega archivos ignorados por .gitignore. */
|
|
140
|
+
force?: boolean;
|
|
141
|
+
}
|
|
142
|
+
export declare function add(files: string[] | string, opts?: GitAddOptions | ExecOptions): Promise<ExecResult>;
|
|
143
|
+
export interface GitCommitOptions extends GitCommon {
|
|
144
|
+
/** Archivos a agregar automáticamente antes del commit (o "."). */
|
|
145
|
+
files?: string[] | string;
|
|
146
|
+
/** `-a`: hace add de los archivos modificados/eliminados rastreados. */
|
|
147
|
+
all?: boolean;
|
|
148
|
+
/** `--allow-empty`: permite commit sin cambios. */
|
|
149
|
+
allowEmpty?: boolean;
|
|
150
|
+
/** `--amend`: reemplaza el último commit en vez de crear uno nuevo. */
|
|
151
|
+
amend?: boolean;
|
|
152
|
+
}
|
|
153
|
+
/** Versión tipo: se traen los archivos indicados (si hay) y se commitea. */
|
|
154
|
+
export declare function commit(message: string, ...rest: Array<string[] | string | GitCommitOptions>): Promise<ExecResult>;
|
|
155
|
+
export interface GitPushOptions extends GitCommon {
|
|
156
|
+
/** Remote destino (ej. "origin"). */
|
|
157
|
+
remote?: string;
|
|
158
|
+
/** Rama/refspec a publicar (ej. "main"). */
|
|
159
|
+
branch?: string;
|
|
160
|
+
/** `--tags`: publica también las etiquetas. */
|
|
161
|
+
tags?: boolean;
|
|
162
|
+
/** `--force`: fuerza el push descartando conflicto remoto. */
|
|
163
|
+
force?: boolean;
|
|
164
|
+
/** `--force-with-lease`: fuerza solo si el remoto no avanzó desde nuestro fetch. */
|
|
165
|
+
forceWithLease?: boolean;
|
|
166
|
+
/** `-u`: setea el upstream para próximos pull/push sin argumentos. */
|
|
167
|
+
setUpstream?: boolean;
|
|
168
|
+
}
|
|
169
|
+
/** `git.push("origin", "main")` o `git.push({ remote: "origin", branch: "main", force: true })`. */
|
|
170
|
+
export declare function push(...rawArgs: Array<string | GitPushOptions>): Promise<ExecResult>;
|
|
171
|
+
export interface GitTagOptions extends GitCommon {
|
|
172
|
+
/** `-m <mgs>` con `-a`: crea una tag anotada con mensaje. */
|
|
173
|
+
message?: string;
|
|
174
|
+
/** `-a`: fuerza tag anotada (suele combinarse con message). */
|
|
175
|
+
annotated?: boolean;
|
|
176
|
+
/** `-f`: reemplaza una tag existente. */
|
|
177
|
+
force?: boolean;
|
|
178
|
+
}
|
|
179
|
+
export declare function tag(name: string, opts?: GitTagOptions | ExecOptions): Promise<ExecResult>;
|
|
180
|
+
export declare function tagDelete(name: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
181
|
+
export interface GitTagListOptions extends GitCommon {
|
|
182
|
+
/** Patrón de filtro (ej. "v1.*"). */
|
|
183
|
+
pattern?: string;
|
|
184
|
+
/** `--sort=-creatordate`: ordena por fecha de creación. */
|
|
185
|
+
sort?: string;
|
|
186
|
+
}
|
|
187
|
+
export declare function tagList(opts?: GitTagListOptions | ExecOptions): Promise<ExecResult>;
|
|
188
|
+
export interface GitMergeOptions extends GitCommon {
|
|
189
|
+
/** `-m <msg>`: mensaje del commit de merge. */
|
|
190
|
+
message?: string;
|
|
191
|
+
/** `--no-edit`: usa el mensaje default sin abrir editor. */
|
|
192
|
+
noEdit?: boolean;
|
|
193
|
+
/** `--ff-only`: aborta si no se puede hacer fast-forward. */
|
|
194
|
+
ffOnly?: boolean;
|
|
195
|
+
/** `--no-ff`: crea commit de merge aunque haya fast-forward. */
|
|
196
|
+
noFF?: boolean;
|
|
197
|
+
/** `--abort`: aborta un merge en conflicto. */
|
|
198
|
+
abort?: boolean;
|
|
199
|
+
}
|
|
200
|
+
/** `merge("develop", { noEdit: true })`, `merge({ abort: true })` o `merge("main", { ffOnly: true })`. */
|
|
201
|
+
export declare function merge(...rawArgs: Array<string | GitMergeOptions>): Promise<ExecResult>;
|
|
202
|
+
export interface GitRebaseOptions extends GitCommon {
|
|
203
|
+
/** Rama base (`git rebase main`). */
|
|
204
|
+
branch?: string;
|
|
205
|
+
/** `--onto <base>`: base concreta para reaplicar. */
|
|
206
|
+
onto?: string;
|
|
207
|
+
/** `--interactive`: abre editor para reordenar commits. */
|
|
208
|
+
interactive?: boolean;
|
|
209
|
+
/** `--continue`: continúa tras resolver conflictos. */
|
|
210
|
+
continue?: boolean;
|
|
211
|
+
/** `--abort`: aborta el rebase en curso. */
|
|
212
|
+
abort?: boolean;
|
|
213
|
+
/** `--skip`: salta el commit conflictivo. */
|
|
214
|
+
skip?: boolean;
|
|
215
|
+
}
|
|
216
|
+
export declare function rebase(opts?: GitRebaseOptions | ExecOptions): Promise<ExecResult>;
|
|
217
|
+
export interface GitStatusOptions extends GitCommon {
|
|
218
|
+
/** `-s`: salida corta. */
|
|
219
|
+
short?: boolean;
|
|
220
|
+
/** `-b`: muestra la rama actual (con -s). */
|
|
221
|
+
branch?: boolean;
|
|
222
|
+
/** `--porcelain`: salida estable para scripting. */
|
|
223
|
+
porcelain?: boolean;
|
|
224
|
+
/** `--untracked-files=no|normal|all`. */
|
|
225
|
+
untrackedFiles?: "no" | "normal" | "all";
|
|
226
|
+
}
|
|
227
|
+
export declare function status(opts?: GitStatusOptions | ExecOptions): Promise<ExecResult>;
|
|
228
|
+
export interface GitLogOptions extends GitCommon {
|
|
229
|
+
/** `--max-count <n>`: limita a los n commits más recientes. */
|
|
230
|
+
maxCount?: number;
|
|
231
|
+
/** `--since <fecha>`: commits desde una fecha/expresión. */
|
|
232
|
+
since?: string;
|
|
233
|
+
/** `--until <fecha>`: commits hasta una fecha/expresión. */
|
|
234
|
+
until?: string;
|
|
235
|
+
/** `--author <patron>`: filtra por autor. */
|
|
236
|
+
author?: string;
|
|
237
|
+
/** `--oneline`: resumen de una línea por commit. */
|
|
238
|
+
oneline?: boolean;
|
|
239
|
+
/** `--graph`: muestra el grafo de ramas. */
|
|
240
|
+
graph?: boolean;
|
|
241
|
+
/** `--all`: incluye todas las ramas. */
|
|
242
|
+
allBranches?: boolean;
|
|
243
|
+
/** `--pretty=format:<fmt>`: formato personalizado (NOTA: usa %h, %s, %an, ...). */
|
|
244
|
+
format?: string;
|
|
245
|
+
/** Rama o rango a consultar. */
|
|
246
|
+
branch?: string;
|
|
247
|
+
}
|
|
248
|
+
export declare function log(opts?: GitLogOptions | ExecOptions): Promise<ExecResult>;
|
|
249
|
+
export interface GitDiffOptions extends GitCommon {
|
|
250
|
+
/** `--cached`: diff del índice (staged). */
|
|
251
|
+
cached?: boolean;
|
|
252
|
+
/** `--stat`: resumen de archivos cambiados. */
|
|
253
|
+
stat?: boolean;
|
|
254
|
+
/** `--name-only`: solo nombres de archivos. */
|
|
255
|
+
nameOnly?: boolean;
|
|
256
|
+
/** Archivos/rangos a comparar. */
|
|
257
|
+
files?: string[] | string;
|
|
258
|
+
}
|
|
259
|
+
export declare function diff(opts?: GitDiffOptions | ExecOptions): Promise<ExecResult>;
|
|
260
|
+
export interface GitShowOptions extends GitCommon {
|
|
261
|
+
/** `--stat`: resumen de archivos del commit. */
|
|
262
|
+
stat?: boolean;
|
|
263
|
+
/** `--name-only`: solo nombres de archivos. */
|
|
264
|
+
nameOnly?: boolean;
|
|
265
|
+
}
|
|
266
|
+
export declare function show(ref: string, opts?: GitShowOptions | ExecOptions): Promise<ExecResult>;
|
|
267
|
+
export interface GitRemoteOptions extends GitCommon {
|
|
268
|
+
/** `-v`: lista remotes con sus URLs. */
|
|
269
|
+
verbose?: boolean;
|
|
270
|
+
/** `git remote show <name>`: detalle de un remote. */
|
|
271
|
+
show?: string;
|
|
272
|
+
/** `git remote get-url <name>`. */
|
|
273
|
+
getUrl?: string;
|
|
274
|
+
}
|
|
275
|
+
export declare function remote(opts?: GitRemoteOptions | ExecOptions): Promise<ExecResult>;
|
|
276
|
+
export declare function remoteAdd(name: string, url: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
277
|
+
export declare function remoteRemove(name: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
278
|
+
export declare function remoteSetUrl(name: string, url: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
279
|
+
export interface GitStashOptions extends GitCommon {
|
|
280
|
+
/** `-m <msg>`: mensaje descriptivo del stash. */
|
|
281
|
+
message?: string;
|
|
282
|
+
/** `-k`: mantiene el índice (deja staged lo que estaba staged). */
|
|
283
|
+
keepIndex?: boolean;
|
|
284
|
+
/** `-u`: incluye archivos untracked. */
|
|
285
|
+
includeUntracked?: boolean;
|
|
286
|
+
/** `-q`: sin salida. */
|
|
287
|
+
quiet?: boolean;
|
|
288
|
+
}
|
|
289
|
+
export declare function stashPush(opts?: GitStashOptions | ExecOptions): Promise<ExecResult>;
|
|
290
|
+
export interface GitStashIndexOptions extends GitCommon {
|
|
291
|
+
/** Índice del stash: `stash@{n}`. */
|
|
292
|
+
index?: number;
|
|
293
|
+
}
|
|
294
|
+
export declare function stashPop(opts?: GitStashIndexOptions | ExecOptions): Promise<ExecResult>;
|
|
295
|
+
export declare function stashApply(opts?: GitStashIndexOptions | ExecOptions): Promise<ExecResult>;
|
|
296
|
+
export declare function stashList(opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
297
|
+
export declare function stashDrop(opts?: GitStashIndexOptions | ExecOptions): Promise<ExecResult>;
|
|
298
|
+
export interface GitResetOptions extends GitCommon {
|
|
299
|
+
/** `--soft | --mixed | --hard`. */
|
|
300
|
+
mode?: "soft" | "mixed" | "hard";
|
|
301
|
+
/** Commit al que volver (por defecto HEAD). */
|
|
302
|
+
commit?: string;
|
|
303
|
+
}
|
|
304
|
+
export declare function reset(opts?: GitResetOptions | ExecOptions): Promise<ExecResult>;
|
|
305
|
+
export interface GitInitOptions extends GitCommon {
|
|
306
|
+
/** `--bare`: repo sin working tree. */
|
|
307
|
+
bare?: boolean;
|
|
308
|
+
/** `-b <name>`: rama inicial (ej. "main"). */
|
|
309
|
+
initialBranch?: string;
|
|
310
|
+
}
|
|
311
|
+
export declare function init(opts?: GitInitOptions | ExecOptions): Promise<ExecResult>;
|
|
312
|
+
export declare function configGet(name: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
313
|
+
export declare function configSet(name: string, value: string, opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
314
|
+
export declare function configList(opts?: GitCommon | ExecOptions): Promise<ExecResult>;
|
|
315
|
+
export interface GitRevParseOptions extends GitCommon {
|
|
316
|
+
/** Ref a resolver (por defecto "HEAD"). */
|
|
317
|
+
ref?: string;
|
|
318
|
+
/** `--short`: SHA abreviado. */
|
|
319
|
+
short?: boolean;
|
|
320
|
+
/** `--verify`: falla si el ref no existe. */
|
|
321
|
+
verify?: boolean;
|
|
322
|
+
/** `--abbrev-ref`: nombre corto de la rama (branch actual). */
|
|
323
|
+
abbrevRef?: boolean;
|
|
324
|
+
/** `--show-toplevel`: ruta absoluta de la raíz del repo. */
|
|
325
|
+
showTopLevel?: boolean;
|
|
326
|
+
}
|
|
327
|
+
/** `revParse()`, `revParse("HEAD~1")` o `revParse({ short: true })`. */
|
|
328
|
+
export declare function revParse(...rawArgs: Array<string | GitRevParseOptions>): Promise<ExecResult>;
|
package/dist/services/git.js
CHANGED
|
@@ -1,36 +1,536 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isBareExec = isBareExec;
|
|
3
4
|
exports.clone = clone;
|
|
4
5
|
exports.checkout = checkout;
|
|
6
|
+
exports.branch = branch;
|
|
7
|
+
exports.branchCreate = branchCreate;
|
|
8
|
+
exports.branchDelete = branchDelete;
|
|
9
|
+
exports.branchRename = branchRename;
|
|
10
|
+
exports.branchList = branchList;
|
|
11
|
+
exports.branchShowCurrent = branchShowCurrent;
|
|
12
|
+
exports.branchSetUpstream = branchSetUpstream;
|
|
13
|
+
exports.branchUnsetUpstream = branchUnsetUpstream;
|
|
5
14
|
exports.pull = pull;
|
|
6
15
|
exports.fetch = fetch;
|
|
7
|
-
exports.
|
|
16
|
+
exports.add = add;
|
|
8
17
|
exports.commit = commit;
|
|
9
18
|
exports.push = push;
|
|
19
|
+
exports.tag = tag;
|
|
20
|
+
exports.tagDelete = tagDelete;
|
|
21
|
+
exports.tagList = tagList;
|
|
22
|
+
exports.merge = merge;
|
|
23
|
+
exports.rebase = rebase;
|
|
24
|
+
exports.status = status;
|
|
25
|
+
exports.log = log;
|
|
26
|
+
exports.diff = diff;
|
|
27
|
+
exports.show = show;
|
|
28
|
+
exports.remote = remote;
|
|
29
|
+
exports.remoteAdd = remoteAdd;
|
|
30
|
+
exports.remoteRemove = remoteRemove;
|
|
31
|
+
exports.remoteSetUrl = remoteSetUrl;
|
|
32
|
+
exports.stashPush = stashPush;
|
|
33
|
+
exports.stashPop = stashPop;
|
|
34
|
+
exports.stashApply = stashApply;
|
|
35
|
+
exports.stashList = stashList;
|
|
36
|
+
exports.stashDrop = stashDrop;
|
|
37
|
+
exports.reset = reset;
|
|
38
|
+
exports.init = init;
|
|
39
|
+
exports.configGet = configGet;
|
|
40
|
+
exports.configSet = configSet;
|
|
41
|
+
exports.configList = configList;
|
|
10
42
|
exports.revParse = revParse;
|
|
11
43
|
const shell_1 = require("./shell");
|
|
12
|
-
|
|
13
|
-
|
|
44
|
+
const EXEC_KEYS = ["retry", "retryDelay", "timeout", "dryRun", "shell", "env"];
|
|
45
|
+
function isRecord(value) {
|
|
46
|
+
return Boolean(value) && typeof value === "object" && !Array.isArray(value);
|
|
47
|
+
}
|
|
48
|
+
/** True si el objeto solo contiene claves de ExecOptions (retry/timeout/dryRun/env...). */
|
|
49
|
+
function isBareExec(value) {
|
|
50
|
+
if (!isRecord(value))
|
|
51
|
+
return false;
|
|
52
|
+
return Object.keys(value).every(key => EXEC_KEYS.includes(key));
|
|
53
|
+
}
|
|
54
|
+
/** Separa los argumentos posicionales (strings) del objeto de opciones final. */
|
|
55
|
+
function splitArgs(rawArgs) {
|
|
56
|
+
const positional = [];
|
|
57
|
+
let options = {};
|
|
58
|
+
for (const arg of rawArgs) {
|
|
59
|
+
if (typeof arg === "string")
|
|
60
|
+
positional.push(arg);
|
|
61
|
+
else if (isRecord(arg))
|
|
62
|
+
options = arg;
|
|
63
|
+
}
|
|
64
|
+
return { positional, options };
|
|
65
|
+
}
|
|
66
|
+
/** Devuelve el ExecOptions a pasar a shell.exec, o undefined si el objeto está vacío. */
|
|
67
|
+
function toExec(value) {
|
|
68
|
+
if (value === undefined)
|
|
69
|
+
return undefined;
|
|
70
|
+
if (isBareExec(value)) {
|
|
71
|
+
return Object.keys(value).length ? value : undefined;
|
|
72
|
+
}
|
|
73
|
+
return value.exec;
|
|
74
|
+
}
|
|
75
|
+
/** Normaliza el último argumento: objeto de opciones o ExecOptions plano. */
|
|
76
|
+
function lastOptions(opts) {
|
|
77
|
+
if (opts === undefined || isBareExec(opts)) {
|
|
78
|
+
return { options: {}, exec: toExec(opts) };
|
|
79
|
+
}
|
|
80
|
+
return { options: opts, exec: opts.exec };
|
|
81
|
+
}
|
|
82
|
+
function toTargets(files) {
|
|
83
|
+
return Array.isArray(files) ? files : [files];
|
|
84
|
+
}
|
|
85
|
+
function clone(url, targetPath, opts = {}) {
|
|
86
|
+
const { options, exec } = lastOptions(opts);
|
|
87
|
+
const args = ["clone"];
|
|
88
|
+
if (options.branch)
|
|
89
|
+
args.push("--branch", options.branch);
|
|
90
|
+
if (options.depth !== undefined)
|
|
91
|
+
args.push("--depth", String(options.depth));
|
|
92
|
+
if (options.bare)
|
|
93
|
+
args.push("--bare");
|
|
94
|
+
if (options.singleBranch)
|
|
95
|
+
args.push("--single-branch");
|
|
96
|
+
args.push(url, targetPath);
|
|
97
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
98
|
+
}
|
|
99
|
+
function checkout(branch, opts = {}) {
|
|
100
|
+
const { options, exec } = lastOptions(opts);
|
|
101
|
+
const args = ["checkout"];
|
|
102
|
+
if (options.create)
|
|
103
|
+
args.push("-b");
|
|
104
|
+
if (options.track)
|
|
105
|
+
args.push("--track");
|
|
106
|
+
if (options.force)
|
|
107
|
+
args.push("-f");
|
|
108
|
+
if (options.detach)
|
|
109
|
+
args.push("--detach");
|
|
110
|
+
args.push(branch);
|
|
111
|
+
if (options.startPoint)
|
|
112
|
+
args.push(options.startPoint);
|
|
113
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
114
|
+
}
|
|
115
|
+
function branch(opts = {}) {
|
|
116
|
+
const { options, exec } = lastOptions(opts);
|
|
117
|
+
const args = ["branch"];
|
|
118
|
+
if (options.showCurrent)
|
|
119
|
+
args.push("--show-current");
|
|
120
|
+
if (options.all)
|
|
121
|
+
args.push("--all");
|
|
122
|
+
if (options.delete || options.forceDelete) {
|
|
123
|
+
const target = options.delete || options.forceDelete;
|
|
124
|
+
args.push(options.forceDelete ? "-D" : "-d", target);
|
|
125
|
+
}
|
|
126
|
+
else if (options.create) {
|
|
127
|
+
if (options.forceCreate)
|
|
128
|
+
args.push("-f");
|
|
129
|
+
args.push(options.create);
|
|
130
|
+
if (options.startPoint)
|
|
131
|
+
args.push(options.startPoint);
|
|
132
|
+
}
|
|
133
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
134
|
+
}
|
|
135
|
+
function branchCreate(name, opts = {}) {
|
|
136
|
+
const { options, exec } = lastOptions(opts);
|
|
137
|
+
const args = ["branch"];
|
|
138
|
+
if (options.force)
|
|
139
|
+
args.push("-f");
|
|
140
|
+
if (options.track)
|
|
141
|
+
args.push("--track");
|
|
142
|
+
args.push(name);
|
|
143
|
+
if (options.startPoint)
|
|
144
|
+
args.push(options.startPoint);
|
|
145
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
146
|
+
}
|
|
147
|
+
function branchDelete(name, opts = {}) {
|
|
148
|
+
const { options, exec } = lastOptions(opts);
|
|
149
|
+
const args = ["branch", options.force ? "-D" : "-d", name];
|
|
150
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
151
|
+
}
|
|
152
|
+
function branchRename(newName, opts = {}) {
|
|
153
|
+
const { options, exec } = lastOptions(opts);
|
|
154
|
+
const args = ["branch", options.force ? "-M" : "-m"];
|
|
155
|
+
if (options.oldName)
|
|
156
|
+
args.push(options.oldName);
|
|
157
|
+
args.push(newName);
|
|
158
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
159
|
+
}
|
|
160
|
+
function branchList(opts = {}) {
|
|
161
|
+
const { options, exec } = lastOptions(opts);
|
|
162
|
+
const args = ["branch", "--list"];
|
|
163
|
+
if (options.all)
|
|
164
|
+
args.push("-a");
|
|
165
|
+
if (options.remote)
|
|
166
|
+
args.push("-r");
|
|
167
|
+
if (options.verbose)
|
|
168
|
+
args.push("-vv");
|
|
169
|
+
if (options.merged !== undefined) {
|
|
170
|
+
args.push("--merged");
|
|
171
|
+
if (typeof options.merged === "string")
|
|
172
|
+
args.push(options.merged);
|
|
173
|
+
}
|
|
174
|
+
if (options.noMerged !== undefined) {
|
|
175
|
+
args.push("--no-merged");
|
|
176
|
+
if (typeof options.noMerged === "string")
|
|
177
|
+
args.push(options.noMerged);
|
|
178
|
+
}
|
|
179
|
+
if (options.contains)
|
|
180
|
+
args.push("--contains", options.contains);
|
|
181
|
+
if (options.sort)
|
|
182
|
+
args.push(`--sort=${options.sort}`);
|
|
183
|
+
if (options.pattern)
|
|
184
|
+
args.push(options.pattern);
|
|
185
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
186
|
+
}
|
|
187
|
+
function branchShowCurrent(opts = {}) {
|
|
188
|
+
const { exec } = lastOptions(opts);
|
|
189
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["branch", "--show-current"], exec));
|
|
190
|
+
}
|
|
191
|
+
function branchSetUpstream(opts = {}) {
|
|
192
|
+
const { options, exec } = lastOptions(opts);
|
|
193
|
+
const args = ["branch", "-u", options.upstream];
|
|
194
|
+
if (options.name)
|
|
195
|
+
args.push(options.name);
|
|
196
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
197
|
+
}
|
|
198
|
+
function branchUnsetUpstream(name, opts = {}) {
|
|
199
|
+
const { exec } = lastOptions(opts);
|
|
200
|
+
const args = ["branch", "--unset-upstream"];
|
|
201
|
+
if (name)
|
|
202
|
+
args.push(name);
|
|
203
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
204
|
+
}
|
|
205
|
+
function pull(opts = {}) {
|
|
206
|
+
const { options, exec } = lastOptions(opts);
|
|
207
|
+
const args = ["pull"];
|
|
208
|
+
if (options.remote)
|
|
209
|
+
args.push(options.remote);
|
|
210
|
+
if (options.branch)
|
|
211
|
+
args.push(options.branch);
|
|
212
|
+
if (options.rebase)
|
|
213
|
+
args.push("--rebase");
|
|
214
|
+
if (options.noRebase)
|
|
215
|
+
args.push("--no-rebase");
|
|
216
|
+
if (options.ffOnly)
|
|
217
|
+
args.push("--ff-only");
|
|
218
|
+
if (options.noFF)
|
|
219
|
+
args.push("--no-ff");
|
|
220
|
+
if (options.prune)
|
|
221
|
+
args.push("--prune");
|
|
222
|
+
if (options.tags)
|
|
223
|
+
args.push("--tags");
|
|
224
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
225
|
+
}
|
|
226
|
+
function fetch(opts = {}) {
|
|
227
|
+
const { options, exec } = lastOptions(opts);
|
|
228
|
+
const args = ["fetch"];
|
|
229
|
+
if (options.depth !== undefined)
|
|
230
|
+
args.push("--depth", String(options.depth));
|
|
231
|
+
if (options.unshallow)
|
|
232
|
+
args.push("--unshallow");
|
|
233
|
+
if (options.prune)
|
|
234
|
+
args.push("--prune");
|
|
235
|
+
if (options.tags)
|
|
236
|
+
args.push("--tags");
|
|
237
|
+
if (options.remote) {
|
|
238
|
+
args.push(options.remote);
|
|
239
|
+
if (options.branch)
|
|
240
|
+
args.push(options.branch);
|
|
241
|
+
}
|
|
242
|
+
else if (options.all !== false) {
|
|
243
|
+
args.push("--all");
|
|
244
|
+
}
|
|
245
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
246
|
+
}
|
|
247
|
+
function add(files, opts = {}) {
|
|
248
|
+
const { options, exec } = lastOptions(opts);
|
|
249
|
+
const args = ["add"];
|
|
250
|
+
if (options.all)
|
|
251
|
+
args.push("-A");
|
|
252
|
+
if (options.update)
|
|
253
|
+
args.push("-u");
|
|
254
|
+
if (options.force)
|
|
255
|
+
args.push("-f");
|
|
256
|
+
args.push(...toTargets(files));
|
|
257
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
258
|
+
}
|
|
259
|
+
/** Versión tipo: se traen los archivos indicados (si hay) y se commitea. */
|
|
260
|
+
async function commit(message, ...rest) {
|
|
261
|
+
const files = [];
|
|
262
|
+
let options = {};
|
|
263
|
+
for (const arg of rest) {
|
|
264
|
+
if (typeof arg === "string" || Array.isArray(arg)) {
|
|
265
|
+
files.push(...toTargets(arg));
|
|
266
|
+
}
|
|
267
|
+
else if (isRecord(arg)) {
|
|
268
|
+
options = arg;
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
const exec = toExec(options);
|
|
272
|
+
const targets = [...files, ...toTargets(options.files ?? [])];
|
|
273
|
+
if (targets.length > 0) {
|
|
274
|
+
await add(targets, exec);
|
|
275
|
+
}
|
|
276
|
+
const args = ["commit"];
|
|
277
|
+
if (options.all)
|
|
278
|
+
args.push("-a");
|
|
279
|
+
if (options.allowEmpty)
|
|
280
|
+
args.push("--allow-empty");
|
|
281
|
+
if (options.amend)
|
|
282
|
+
args.push("--amend");
|
|
283
|
+
args.push("-m", message);
|
|
284
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
285
|
+
}
|
|
286
|
+
/** `git.push("origin", "main")` o `git.push({ remote: "origin", branch: "main", force: true })`. */
|
|
287
|
+
function push(...rawArgs) {
|
|
288
|
+
const { positional, options } = splitArgs(rawArgs);
|
|
289
|
+
const exec = toExec(options);
|
|
290
|
+
const args = ["push"];
|
|
291
|
+
const remote = options.remote ?? positional[0];
|
|
292
|
+
const branch = options.branch ?? positional[1];
|
|
293
|
+
if (remote)
|
|
294
|
+
args.push(remote);
|
|
295
|
+
if (branch)
|
|
296
|
+
args.push(branch);
|
|
297
|
+
if (options.tags)
|
|
298
|
+
args.push("--tags");
|
|
299
|
+
if (options.force)
|
|
300
|
+
args.push("--force");
|
|
301
|
+
else if (options.forceWithLease)
|
|
302
|
+
args.push("--force-with-lease");
|
|
303
|
+
if (options.setUpstream)
|
|
304
|
+
args.push("-u");
|
|
305
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
306
|
+
}
|
|
307
|
+
function tag(name, opts = {}) {
|
|
308
|
+
const { options, exec } = lastOptions(opts);
|
|
309
|
+
const args = ["tag"];
|
|
310
|
+
if (options.annotated || options.message)
|
|
311
|
+
args.push("-a");
|
|
312
|
+
if (options.force)
|
|
313
|
+
args.push("-f");
|
|
314
|
+
args.push(name);
|
|
315
|
+
if (options.message)
|
|
316
|
+
args.push("-m", options.message);
|
|
317
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
318
|
+
}
|
|
319
|
+
function tagDelete(name, opts = {}) {
|
|
320
|
+
const { exec } = lastOptions(opts);
|
|
321
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["tag", "-d", name], exec));
|
|
322
|
+
}
|
|
323
|
+
function tagList(opts = {}) {
|
|
324
|
+
const { options, exec } = lastOptions(opts);
|
|
325
|
+
const args = ["tag", "--list"];
|
|
326
|
+
if (options.sort)
|
|
327
|
+
args.push(`--sort=${options.sort}`);
|
|
328
|
+
if (options.pattern)
|
|
329
|
+
args.push(options.pattern);
|
|
330
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
331
|
+
}
|
|
332
|
+
/** `merge("develop", { noEdit: true })`, `merge({ abort: true })` o `merge("main", { ffOnly: true })`. */
|
|
333
|
+
function merge(...rawArgs) {
|
|
334
|
+
const { positional, options } = splitArgs(rawArgs);
|
|
335
|
+
const exec = toExec(options);
|
|
336
|
+
const branch = positional[0];
|
|
337
|
+
const args = ["merge"];
|
|
338
|
+
if (options.noEdit)
|
|
339
|
+
args.push("--no-edit");
|
|
340
|
+
if (options.ffOnly)
|
|
341
|
+
args.push("--ff-only");
|
|
342
|
+
if (options.noFF)
|
|
343
|
+
args.push("--no-ff");
|
|
344
|
+
if (options.abort)
|
|
345
|
+
args.push("--abort");
|
|
346
|
+
else {
|
|
347
|
+
if (options.message)
|
|
348
|
+
args.push("-m", options.message);
|
|
349
|
+
if (branch)
|
|
350
|
+
args.push(branch);
|
|
351
|
+
}
|
|
352
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
353
|
+
}
|
|
354
|
+
function rebase(opts = {}) {
|
|
355
|
+
const { options, exec } = lastOptions(opts);
|
|
356
|
+
const args = ["rebase"];
|
|
357
|
+
if (options.interactive)
|
|
358
|
+
args.push("--interactive");
|
|
359
|
+
if (options.continue)
|
|
360
|
+
args.push("--continue");
|
|
361
|
+
if (options.abort)
|
|
362
|
+
args.push("--abort");
|
|
363
|
+
if (options.skip)
|
|
364
|
+
args.push("--skip");
|
|
365
|
+
if (options.onto)
|
|
366
|
+
args.push("--onto", options.onto);
|
|
367
|
+
if (options.branch)
|
|
368
|
+
args.push(options.branch);
|
|
369
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
370
|
+
}
|
|
371
|
+
function status(opts = {}) {
|
|
372
|
+
const { options, exec } = lastOptions(opts);
|
|
373
|
+
const args = ["status"];
|
|
374
|
+
if (options.short)
|
|
375
|
+
args.push("-s");
|
|
376
|
+
if (options.branch)
|
|
377
|
+
args.push("-b");
|
|
378
|
+
if (options.porcelain)
|
|
379
|
+
args.push("--porcelain");
|
|
380
|
+
if (options.untrackedFiles !== undefined)
|
|
381
|
+
args.push(`--untracked-files=${options.untrackedFiles}`);
|
|
382
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
383
|
+
}
|
|
384
|
+
function log(opts = {}) {
|
|
385
|
+
const { options, exec } = lastOptions(opts);
|
|
386
|
+
const args = ["log"];
|
|
387
|
+
if (options.maxCount !== undefined)
|
|
388
|
+
args.push("--max-count", String(options.maxCount));
|
|
389
|
+
if (options.since)
|
|
390
|
+
args.push("--since", options.since);
|
|
391
|
+
if (options.until)
|
|
392
|
+
args.push("--until", options.until);
|
|
393
|
+
if (options.author)
|
|
394
|
+
args.push("--author", options.author);
|
|
395
|
+
if (options.oneline)
|
|
396
|
+
args.push("--oneline");
|
|
397
|
+
if (options.graph)
|
|
398
|
+
args.push("--graph");
|
|
399
|
+
if (options.allBranches)
|
|
400
|
+
args.push("--all");
|
|
401
|
+
if (options.format)
|
|
402
|
+
args.push(`--pretty=format:${options.format}`);
|
|
403
|
+
if (options.branch)
|
|
404
|
+
args.push(options.branch);
|
|
405
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
406
|
+
}
|
|
407
|
+
function diff(opts = {}) {
|
|
408
|
+
const { options, exec } = lastOptions(opts);
|
|
409
|
+
const args = ["diff"];
|
|
410
|
+
if (options.cached)
|
|
411
|
+
args.push("--cached");
|
|
412
|
+
if (options.stat)
|
|
413
|
+
args.push("--stat");
|
|
414
|
+
if (options.nameOnly)
|
|
415
|
+
args.push("--name-only");
|
|
416
|
+
args.push(...toTargets(options.files ?? []));
|
|
417
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
418
|
+
}
|
|
419
|
+
function show(ref, opts = {}) {
|
|
420
|
+
const { options, exec } = lastOptions(opts);
|
|
421
|
+
const args = ["show"];
|
|
422
|
+
if (options.stat)
|
|
423
|
+
args.push("--stat");
|
|
424
|
+
if (options.nameOnly)
|
|
425
|
+
args.push("--name-only");
|
|
426
|
+
args.push(ref);
|
|
427
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
428
|
+
}
|
|
429
|
+
function remote(opts = {}) {
|
|
430
|
+
const { options, exec } = lastOptions(opts);
|
|
431
|
+
const args = ["remote"];
|
|
432
|
+
if (options.verbose)
|
|
433
|
+
args.push("-v");
|
|
434
|
+
if (options.show)
|
|
435
|
+
args.push("show", options.show);
|
|
436
|
+
else if (options.getUrl)
|
|
437
|
+
args.push("get-url", options.getUrl);
|
|
438
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
439
|
+
}
|
|
440
|
+
function remoteAdd(name, url, opts = {}) {
|
|
441
|
+
const { exec } = lastOptions(opts);
|
|
442
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["remote", "add", name, url], exec));
|
|
443
|
+
}
|
|
444
|
+
function remoteRemove(name, opts = {}) {
|
|
445
|
+
const { exec } = lastOptions(opts);
|
|
446
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["remote", "remove", name], exec));
|
|
447
|
+
}
|
|
448
|
+
function remoteSetUrl(name, url, opts = {}) {
|
|
449
|
+
const { exec } = lastOptions(opts);
|
|
450
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["remote", "set-url", name, url], exec));
|
|
451
|
+
}
|
|
452
|
+
function stashPush(opts = {}) {
|
|
453
|
+
const { options, exec } = lastOptions(opts);
|
|
454
|
+
const args = ["stash", "push"];
|
|
455
|
+
if (options.quiet)
|
|
456
|
+
args.push("-q");
|
|
457
|
+
if (options.keepIndex)
|
|
458
|
+
args.push("-k");
|
|
459
|
+
if (options.includeUntracked)
|
|
460
|
+
args.push("-u");
|
|
461
|
+
if (options.message)
|
|
462
|
+
args.push("-m", options.message);
|
|
463
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
464
|
+
}
|
|
465
|
+
function stashPop(opts = {}) {
|
|
466
|
+
const { options, exec } = lastOptions(opts);
|
|
467
|
+
const args = ["stash", "pop"];
|
|
468
|
+
if (options.index !== undefined)
|
|
469
|
+
args.push(`stash@{${options.index}}`);
|
|
470
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
471
|
+
}
|
|
472
|
+
function stashApply(opts = {}) {
|
|
473
|
+
const { options, exec } = lastOptions(opts);
|
|
474
|
+
const args = ["stash", "apply"];
|
|
475
|
+
if (options.index !== undefined)
|
|
476
|
+
args.push(`stash@{${options.index}}`);
|
|
477
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
478
|
+
}
|
|
479
|
+
function stashList(opts = {}) {
|
|
480
|
+
const { exec } = lastOptions(opts);
|
|
481
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["stash", "list"], exec));
|
|
14
482
|
}
|
|
15
|
-
function
|
|
16
|
-
|
|
483
|
+
function stashDrop(opts = {}) {
|
|
484
|
+
const { options, exec } = lastOptions(opts);
|
|
485
|
+
const args = ["stash", "drop"];
|
|
486
|
+
if (options.index !== undefined)
|
|
487
|
+
args.push(`stash@{${options.index}}`);
|
|
488
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
17
489
|
}
|
|
18
|
-
function
|
|
19
|
-
|
|
490
|
+
function reset(opts = {}) {
|
|
491
|
+
const { options, exec } = lastOptions(opts);
|
|
492
|
+
const args = ["reset"];
|
|
493
|
+
if (options.mode)
|
|
494
|
+
args.push(`--${options.mode}`);
|
|
495
|
+
if (options.commit)
|
|
496
|
+
args.push(options.commit);
|
|
497
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
20
498
|
}
|
|
21
|
-
function
|
|
22
|
-
|
|
499
|
+
function init(opts = {}) {
|
|
500
|
+
const { options, exec } = lastOptions(opts);
|
|
501
|
+
const args = ["init"];
|
|
502
|
+
if (options.bare)
|
|
503
|
+
args.push("--bare");
|
|
504
|
+
if (options.initialBranch)
|
|
505
|
+
args.push("-b", options.initialBranch);
|
|
506
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
23
507
|
}
|
|
24
|
-
function
|
|
25
|
-
|
|
508
|
+
function configGet(name, opts = {}) {
|
|
509
|
+
const { exec } = lastOptions(opts);
|
|
510
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["config", "--get", name], exec));
|
|
26
511
|
}
|
|
27
|
-
function
|
|
28
|
-
|
|
512
|
+
function configSet(name, value, opts = {}) {
|
|
513
|
+
const { exec } = lastOptions(opts);
|
|
514
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["config", name, value], exec));
|
|
29
515
|
}
|
|
30
|
-
function
|
|
31
|
-
|
|
516
|
+
function configList(opts = {}) {
|
|
517
|
+
const { exec } = lastOptions(opts);
|
|
518
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(["config", "--list"], exec));
|
|
32
519
|
}
|
|
33
|
-
|
|
34
|
-
|
|
520
|
+
/** `revParse()`, `revParse("HEAD~1")` o `revParse({ short: true })`. */
|
|
521
|
+
function revParse(...rawArgs) {
|
|
522
|
+
const { positional, options } = splitArgs(rawArgs);
|
|
523
|
+
const exec = toExec(options);
|
|
524
|
+
const args = ["rev-parse"];
|
|
525
|
+
if (options.short)
|
|
526
|
+
args.push("--short");
|
|
527
|
+
if (options.verify)
|
|
528
|
+
args.push("--verify");
|
|
529
|
+
if (options.abbrevRef)
|
|
530
|
+
args.push("--abbrev-ref");
|
|
531
|
+
if (options.showTopLevel)
|
|
532
|
+
args.push("--show-toplevel");
|
|
533
|
+
args.push(options.ref ?? positional[0] ?? "HEAD");
|
|
534
|
+
return shell_1.shell.exec("git", ...(0, shell_1.withExecOptions)(args, exec));
|
|
35
535
|
}
|
|
36
536
|
//# sourceMappingURL=git.js.map
|
package/dist/services/git.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git.js","sourceRoot":"","sources":["../../src/services/git.ts"],"names":[],"mappings":";;AAGA,sBAEC;AAED,4BAEC;AAED,oBAEC;AAED,sBAEC;AAED,kBAEC;AAED,wBAEC;AAED,oBAEC;AAED,4BAEC;AAjCD,mCAAiD;AAGjD,SAAgB,KAAK,CAAC,GAAW,EAAE,UAAkB,EAAE,IAAkB;IACrE,OAAO,aAAK,CAAC,IAAI,CAAC,KAAK,EAAE,GAAG,IAAA,uBAAe,EAAC,CAAC,OAAO,EAAE,GAAG,EAAE,UAAU,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC;AACnF,CAAC;AAED,SAAgB,QAAQ,CAAC,MAAc,EAAE,IAAkB;IACvD,OAAO,aAAK,CAAC,IAAI,CAAC,KAAK,EAAE,GAAG,IAAA,uBAAe,EAAC,CAAC,UAAU,EAAE,MAAM,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC;AAC7E,CAAC;AAED,SAAgB,IAAI,CAAC,IAAkB;IACnC,OAAO,aAAK,CAAC,IAAI,CAAC,KAAK,EAAE,GAAG,IAAA,uBAAe,EAAC,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC;AACjE,CAAC;AAED,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,GAAG,OAA2C;IACnE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,SAAS,CAAqB,OAAO,CAAC,CAAC;IACvE,MAAM,IAAI,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC;IAC7B,MAAM,IAAI,GAAG,CAAC,WAAW,CAAC,CAAC;IAC3B,IAAI,OAAO,CAAC,KAAK;QAAE,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;IACxC,IAAI,OAAO,CAAC,MAAM;QAAE,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IAC1C,IAAI,OAAO,CAAC,SAAS;QAAE,IAAI,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;IACjD,IAAI,OAAO,CAAC,YAAY;QAAE,IAAI,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC;IACvD,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,IAAI,UAAU,CAAC,CAAC,CAAC,IAAI,MAAM,CAAC,CAAC;IAClD,OAAO,aAAK,CAAC,IAAI,CAAC,KAAK,EAAE,GAAG,IAAA,uBAAe,EAAC,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC;AAC7D,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cat-indev/catops-cli",
|
|
3
|
-
"version": "0.0.1-alpha.
|
|
3
|
+
"version": "0.0.1-alpha.41",
|
|
4
4
|
"description": "Framework CLI para pipelines DevOps (shell, docker, git, kubectl, helm, npm, terraform, ansible, argocd, tekton, oc, az) sobre un ExecutionContext compartido, con menus interactivos y selectores automaticos por flag. Escrito en TypeScript, 100% usable desde JavaScript.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|