@kilnci/cli 0.1.0
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/bin/kiln.js +5 -0
- package/dist/base-command.d.ts +21 -0
- package/dist/base-command.d.ts.map +1 -0
- package/dist/base-command.js +30 -0
- package/dist/base-command.js.map +1 -0
- package/dist/client.d.ts +166 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +321 -0
- package/dist/client.js.map +1 -0
- package/dist/commands/artifacts.d.ts +17 -0
- package/dist/commands/artifacts.d.ts.map +1 -0
- package/dist/commands/artifacts.js +96 -0
- package/dist/commands/artifacts.js.map +1 -0
- package/dist/commands/build.d.ts +15 -0
- package/dist/commands/build.d.ts.map +1 -0
- package/dist/commands/build.js +79 -0
- package/dist/commands/build.js.map +1 -0
- package/dist/commands/cancel.d.ts +10 -0
- package/dist/commands/cancel.d.ts.map +1 -0
- package/dist/commands/cancel.js +27 -0
- package/dist/commands/cancel.js.map +1 -0
- package/dist/commands/login.d.ts +18 -0
- package/dist/commands/login.d.ts.map +1 -0
- package/dist/commands/login.js +188 -0
- package/dist/commands/login.js.map +1 -0
- package/dist/commands/logout.d.ts +7 -0
- package/dist/commands/logout.d.ts.map +1 -0
- package/dist/commands/logout.js +17 -0
- package/dist/commands/logout.js.map +1 -0
- package/dist/commands/logs.d.ts +18 -0
- package/dist/commands/logs.d.ts.map +1 -0
- package/dist/commands/logs.js +139 -0
- package/dist/commands/logs.js.map +1 -0
- package/dist/commands/org/create.d.ts +13 -0
- package/dist/commands/org/create.d.ts.map +1 -0
- package/dist/commands/org/create.js +39 -0
- package/dist/commands/org/create.js.map +1 -0
- package/dist/commands/org/delete.d.ts +13 -0
- package/dist/commands/org/delete.d.ts.map +1 -0
- package/dist/commands/org/delete.js +44 -0
- package/dist/commands/org/delete.js.map +1 -0
- package/dist/commands/org/gitlab/remove.d.ts +13 -0
- package/dist/commands/org/gitlab/remove.d.ts.map +1 -0
- package/dist/commands/org/gitlab/remove.js +51 -0
- package/dist/commands/org/gitlab/remove.js.map +1 -0
- package/dist/commands/org/gitlab/setup.d.ts +17 -0
- package/dist/commands/org/gitlab/setup.d.ts.map +1 -0
- package/dist/commands/org/gitlab/setup.js +83 -0
- package/dist/commands/org/gitlab/setup.js.map +1 -0
- package/dist/commands/org/gitlab/show.d.ts +10 -0
- package/dist/commands/org/gitlab/show.d.ts.map +1 -0
- package/dist/commands/org/gitlab/show.js +54 -0
- package/dist/commands/org/gitlab/show.js.map +1 -0
- package/dist/commands/org/gitlab/sync.d.ts +10 -0
- package/dist/commands/org/gitlab/sync.d.ts.map +1 -0
- package/dist/commands/org/gitlab/sync.js +38 -0
- package/dist/commands/org/gitlab/sync.js.map +1 -0
- package/dist/commands/org/index.d.ts +11 -0
- package/dist/commands/org/index.d.ts.map +1 -0
- package/dist/commands/org/index.js +46 -0
- package/dist/commands/org/index.js.map +1 -0
- package/dist/commands/org/repos/disable.d.ts +11 -0
- package/dist/commands/org/repos/disable.d.ts.map +1 -0
- package/dist/commands/org/repos/disable.js +32 -0
- package/dist/commands/org/repos/disable.js.map +1 -0
- package/dist/commands/org/repos/enable.d.ts +11 -0
- package/dist/commands/org/repos/enable.d.ts.map +1 -0
- package/dist/commands/org/repos/enable.js +32 -0
- package/dist/commands/org/repos/enable.js.map +1 -0
- package/dist/commands/org/repos.d.ts +14 -0
- package/dist/commands/org/repos.d.ts.map +1 -0
- package/dist/commands/org/repos.js +54 -0
- package/dist/commands/org/repos.js.map +1 -0
- package/dist/commands/status.d.ts +17 -0
- package/dist/commands/status.d.ts.map +1 -0
- package/dist/commands/status.js +73 -0
- package/dist/commands/status.js.map +1 -0
- package/dist/commands/workers/create.d.ts +15 -0
- package/dist/commands/workers/create.d.ts.map +1 -0
- package/dist/commands/workers/create.js +74 -0
- package/dist/commands/workers/create.js.map +1 -0
- package/dist/commands/workers/delete.d.ts +13 -0
- package/dist/commands/workers/delete.d.ts.map +1 -0
- package/dist/commands/workers/delete.js +40 -0
- package/dist/commands/workers/delete.js.map +1 -0
- package/dist/commands/workers/index.d.ts +10 -0
- package/dist/commands/workers/index.d.ts.map +1 -0
- package/dist/commands/workers/index.js +42 -0
- package/dist/commands/workers/index.js.map +1 -0
- package/dist/commands/workers/logs.d.ts +11 -0
- package/dist/commands/workers/logs.d.ts.map +1 -0
- package/dist/commands/workers/logs.js +54 -0
- package/dist/commands/workers/logs.js.map +1 -0
- package/dist/commands/workers/revoke.d.ts +10 -0
- package/dist/commands/workers/revoke.d.ts.map +1 -0
- package/dist/commands/workers/revoke.js +27 -0
- package/dist/commands/workers/revoke.js.map +1 -0
- package/dist/commands/workers/start.d.ts +19 -0
- package/dist/commands/workers/start.d.ts.map +1 -0
- package/dist/commands/workers/start.js +329 -0
- package/dist/commands/workers/start.js.map +1 -0
- package/dist/commands/workers/status.d.ts +7 -0
- package/dist/commands/workers/status.d.ts.map +1 -0
- package/dist/commands/workers/status.js +75 -0
- package/dist/commands/workers/status.js.map +1 -0
- package/dist/commands/workers/stop.d.ts +10 -0
- package/dist/commands/workers/stop.d.ts.map +1 -0
- package/dist/commands/workers/stop.js +79 -0
- package/dist/commands/workers/stop.js.map +1 -0
- package/dist/commands/workers/token.d.ts +13 -0
- package/dist/commands/workers/token.d.ts.map +1 -0
- package/dist/commands/workers/token.js +38 -0
- package/dist/commands/workers/token.js.map +1 -0
- package/dist/config.d.ts +38 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +68 -0
- package/dist/config.js.map +1 -0
- package/dist/formatters.d.ts +42 -0
- package/dist/formatters.d.ts.map +1 -0
- package/dist/formatters.js +194 -0
- package/dist/formatters.js.map +1 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/workers-helpers.d.ts +20 -0
- package/dist/lib/workers-helpers.d.ts.map +1 -0
- package/dist/lib/workers-helpers.js +51 -0
- package/dist/lib/workers-helpers.js.map +1 -0
- package/package.json +56 -0
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
import * as fs from 'node:fs';
|
|
2
|
+
import * as path from 'node:path';
|
|
3
|
+
import { Args, Flags } from '@oclif/core';
|
|
4
|
+
import { BaseCommand } from '../base-command.js';
|
|
5
|
+
import { LogStreamClient } from '../client.js';
|
|
6
|
+
import { formatLogLine, formatStatus } from '../formatters.js';
|
|
7
|
+
export default class Logs extends BaseCommand {
|
|
8
|
+
static description = 'View build logs';
|
|
9
|
+
static examples = [
|
|
10
|
+
'<%= config.bin %> logs 11111111-1111-1111-1111-111111111111',
|
|
11
|
+
'<%= config.bin %> logs 11111111-1111-1111-1111-111111111111 --follow',
|
|
12
|
+
'<%= config.bin %> logs 11111111-1111-1111-1111-111111111111 --download',
|
|
13
|
+
'<%= config.bin %> logs 11111111-1111-1111-1111-111111111111 --download --output build.log',
|
|
14
|
+
];
|
|
15
|
+
static args = {
|
|
16
|
+
buildId: Args.string({
|
|
17
|
+
description: 'Build ID to view logs for',
|
|
18
|
+
required: true,
|
|
19
|
+
}),
|
|
20
|
+
};
|
|
21
|
+
static flags = {
|
|
22
|
+
follow: Flags.boolean({
|
|
23
|
+
char: 'f',
|
|
24
|
+
description: 'Follow logs in real-time',
|
|
25
|
+
default: false,
|
|
26
|
+
}),
|
|
27
|
+
download: Flags.boolean({
|
|
28
|
+
char: 'd',
|
|
29
|
+
description: 'Download full logs to a file',
|
|
30
|
+
default: false,
|
|
31
|
+
}),
|
|
32
|
+
output: Flags.string({
|
|
33
|
+
char: 'o',
|
|
34
|
+
description: 'Output file path (default: build-<id>.log)',
|
|
35
|
+
}),
|
|
36
|
+
};
|
|
37
|
+
async run() {
|
|
38
|
+
const { args, flags } = await this.parse(Logs);
|
|
39
|
+
this.requireAuth();
|
|
40
|
+
try {
|
|
41
|
+
// First, check that the build exists and show its status
|
|
42
|
+
const build = await this.client.getBuild(args.buildId);
|
|
43
|
+
this.log(`Build ${build.id} - Status: ${formatStatus(build.status)}\n`);
|
|
44
|
+
if (flags.download) {
|
|
45
|
+
// Download full logs to a file
|
|
46
|
+
await this.downloadLogs(args.buildId, flags.output);
|
|
47
|
+
}
|
|
48
|
+
else if (flags.follow) {
|
|
49
|
+
// Real-time log streaming
|
|
50
|
+
await this.followLogs(args.buildId);
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
// For non-follow mode, just show the current status
|
|
54
|
+
if (build.status === 'pending') {
|
|
55
|
+
this.log('Build has not started yet. Use --follow to watch logs when it starts.');
|
|
56
|
+
}
|
|
57
|
+
else if (build.status === 'running') {
|
|
58
|
+
this.log('Build is running. Use --follow to watch logs in real-time.');
|
|
59
|
+
}
|
|
60
|
+
else {
|
|
61
|
+
this.log(`Build finished with status: ${formatStatus(build.status)}`);
|
|
62
|
+
if (build.exitCode !== null) {
|
|
63
|
+
this.log(`Exit code: ${build.exitCode}`);
|
|
64
|
+
}
|
|
65
|
+
if (build.errorMessage) {
|
|
66
|
+
this.log(`Error: ${build.errorMessage}`);
|
|
67
|
+
}
|
|
68
|
+
// Show hint about downloading logs if available
|
|
69
|
+
if (build.artifacts?.logs) {
|
|
70
|
+
this.log(`\nLogs available for download. Use --download to save to file.`);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
catch (error) {
|
|
76
|
+
this.handleError(error, 'get logs');
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
async downloadLogs(buildId, outputPath) {
|
|
80
|
+
this.log('Fetching logs download URL...');
|
|
81
|
+
try {
|
|
82
|
+
const downloadUrl = await this.client.getLogsDownloadUrl(buildId);
|
|
83
|
+
this.log('Downloading logs...');
|
|
84
|
+
const content = await this.client.downloadFile(downloadUrl);
|
|
85
|
+
const filename = outputPath || `build-${buildId.substring(0, 8)}.log`;
|
|
86
|
+
const fullPath = path.resolve(filename);
|
|
87
|
+
fs.writeFileSync(fullPath, content);
|
|
88
|
+
this.log(`Logs saved to: ${fullPath}`);
|
|
89
|
+
this.log(`Size: ${this.formatSize(content.length)}`);
|
|
90
|
+
}
|
|
91
|
+
catch (error) {
|
|
92
|
+
const message = error instanceof Error ? error.message : 'Unknown error';
|
|
93
|
+
if (message.includes('not available') || message.includes('404')) {
|
|
94
|
+
this.error('Logs not available for download. The build may still be running or logs were not stored.');
|
|
95
|
+
}
|
|
96
|
+
throw error;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
formatSize(bytes) {
|
|
100
|
+
if (bytes < 1024)
|
|
101
|
+
return `${bytes} B`;
|
|
102
|
+
if (bytes < 1024 * 1024)
|
|
103
|
+
return `${(bytes / 1024).toFixed(1)} KB`;
|
|
104
|
+
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
105
|
+
}
|
|
106
|
+
async followLogs(buildId) {
|
|
107
|
+
return new Promise((resolve, reject) => {
|
|
108
|
+
const logClient = new LogStreamClient(this.appConfig);
|
|
109
|
+
this.log('Connecting to log stream...\n');
|
|
110
|
+
logClient.connect(buildId, {
|
|
111
|
+
onLog: (log) => {
|
|
112
|
+
this.log(formatLogLine(log.timestamp, log.stream, log.line));
|
|
113
|
+
},
|
|
114
|
+
onStatus: (status) => {
|
|
115
|
+
this.log(`\n--- Build status changed: ${formatStatus(status)} ---\n`);
|
|
116
|
+
if (status === 'success' || status === 'failed' || status === 'cancelled') {
|
|
117
|
+
logClient.close();
|
|
118
|
+
resolve();
|
|
119
|
+
}
|
|
120
|
+
},
|
|
121
|
+
onError: (error) => {
|
|
122
|
+
logClient.close();
|
|
123
|
+
reject(new Error(error));
|
|
124
|
+
},
|
|
125
|
+
onClose: () => {
|
|
126
|
+
this.log('\nDisconnected from log stream.');
|
|
127
|
+
resolve();
|
|
128
|
+
},
|
|
129
|
+
});
|
|
130
|
+
// Handle Ctrl+C
|
|
131
|
+
process.on('SIGINT', () => {
|
|
132
|
+
this.log('\nDisconnecting...');
|
|
133
|
+
logClient.close();
|
|
134
|
+
resolve();
|
|
135
|
+
});
|
|
136
|
+
});
|
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M,KAAK,QAAQ,IAAI,MAAM,KAAK,WAAW,EAAE,CAAC;wBAC1E,SAAS,CAAC,KAAK,EAAE,CAAC;wBAClB,OAAO,EAAE,CAAC;oBACZ,CAAC;gBACH,CAAC;gBACD,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;oBACjB,SAAS,CAAC,KAAK,EAAE,CAAC;oBAClB,MAAM,CAAC,IAAI,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC;gBAC3B,CAAC;gBACD,OAAO,EAAE,GAAG,EAAE;oBACZ,IAAI,CAAC,GAAG,CAAC,iCAAiC,CAAC,CAAC;oBAC5C,OAAO,EAAE,CAAC;gBACZ,CAAC;aACF,CAAC,CAAC;YAEH,gBAAgB;YAChB,OAAO,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;gBACxB,IAAI,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAC;gBAC/B,SAAS,CAAC,KAAK,EAAE,CAAC;gBAClB,OAAO,EAAE,CAAC;YACZ,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { BaseCommand } from '../../base-command.js';
|
|
2
|
+
export default class OrgCreate extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static args: {
|
|
6
|
+
slug: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
7
|
+
};
|
|
8
|
+
static flags: {
|
|
9
|
+
name: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
|
+
};
|
|
11
|
+
run(): Promise<void>;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=create.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/commands/org/create.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,WAAW;IAChD,OAAgB,WAAW,SAA4C;IAEvE,OAAgB,QAAQ,WAEtB;IAEF,OAAgB,IAAI;;MAKlB;IAEF,OAAgB,KAAK;;MAMnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAkBlC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { Args, Flags } from '@oclif/core';
|
|
2
|
+
import { BaseCommand } from '../../base-command.js';
|
|
3
|
+
export default class OrgCreate extends BaseCommand {
|
|
4
|
+
static description = 'Create a new organization (admin only)';
|
|
5
|
+
static examples = [
|
|
6
|
+
'<%= config.bin %> org create enspirit --name "Enspirit SRL"',
|
|
7
|
+
];
|
|
8
|
+
static args = {
|
|
9
|
+
slug: Args.string({
|
|
10
|
+
description: 'Organization slug (lowercase, alphanumeric with dashes)',
|
|
11
|
+
required: true,
|
|
12
|
+
}),
|
|
13
|
+
};
|
|
14
|
+
static flags = {
|
|
15
|
+
name: Flags.string({
|
|
16
|
+
char: 'n',
|
|
17
|
+
description: 'Organization display name',
|
|
18
|
+
required: true,
|
|
19
|
+
}),
|
|
20
|
+
};
|
|
21
|
+
async run() {
|
|
22
|
+
const { args, flags } = await this.parse(OrgCreate);
|
|
23
|
+
this.requireAuth();
|
|
24
|
+
try {
|
|
25
|
+
const org = await this.client.createOrganization({
|
|
26
|
+
slug: args.slug,
|
|
27
|
+
name: flags.name,
|
|
28
|
+
});
|
|
29
|
+
this.log(`Organization created successfully:`);
|
|
30
|
+
this.log(` Slug: ${org.slug}`);
|
|
31
|
+
this.log(` Name: ${org.name}`);
|
|
32
|
+
this.log(` ID: ${org.id}`);
|
|
33
|
+
}
|
|
34
|
+
catch (error) {
|
|
35
|
+
this.handleError(error, 'create organization');
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
//# sourceMappingURL=create.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{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AE,CAAC,CAAC;QAC9B,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,qBAAqB,CAAC,CAAC;QACjD,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { BaseCommand } from '../../base-command.js';
|
|
2
|
+
export default class OrgDelete extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static args: {
|
|
6
|
+
slug: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
7
|
+
};
|
|
8
|
+
static flags: {
|
|
9
|
+
yes: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
10
|
+
};
|
|
11
|
+
run(): Promise<void>;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=delete.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete.d.ts","sourceRoot":"","sources":["../../../src/commands/org/delete.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,WAAW;IAChD,OAAgB,WAAW,SAAyC;IAEpE,OAAgB,QAAQ,WAGtB;IAEF,OAAgB,IAAI;;MAKlB;IAEF,OAAgB,KAAK;;MAMnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAuBlC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { Args, Flags } from '@oclif/core';
|
|
2
|
+
import { BaseCommand } from '../../base-command.js';
|
|
3
|
+
export default class OrgDelete extends BaseCommand {
|
|
4
|
+
static description = 'Delete an organization (admin only)';
|
|
5
|
+
static examples = [
|
|
6
|
+
'<%= config.bin %> org delete my-org',
|
|
7
|
+
'<%= config.bin %> org delete my-org --yes',
|
|
8
|
+
];
|
|
9
|
+
static args = {
|
|
10
|
+
slug: Args.string({
|
|
11
|
+
description: 'Organization slug',
|
|
12
|
+
required: true,
|
|
13
|
+
}),
|
|
14
|
+
};
|
|
15
|
+
static flags = {
|
|
16
|
+
yes: Flags.boolean({
|
|
17
|
+
char: 'y',
|
|
18
|
+
description: 'Skip confirmation prompt',
|
|
19
|
+
default: false,
|
|
20
|
+
}),
|
|
21
|
+
};
|
|
22
|
+
async run() {
|
|
23
|
+
const { args, flags } = await this.parse(OrgDelete);
|
|
24
|
+
this.requireAuth();
|
|
25
|
+
try {
|
|
26
|
+
// Fetch org first to confirm it exists
|
|
27
|
+
const org = await this.client.getOrganization(args.slug);
|
|
28
|
+
if (!flags.yes) {
|
|
29
|
+
this.log(`About to delete organization: ${org.name} (${org.slug})`);
|
|
30
|
+
this.log('This action cannot be undone.');
|
|
31
|
+
this.log('');
|
|
32
|
+
this.log('To confirm, run again with --yes flag:');
|
|
33
|
+
this.log(` kiln org delete ${args.slug} --yes`);
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
await this.client.deleteOrganization(args.slug);
|
|
37
|
+
this.log(`Organization "${org.name}" (${args.slug}) deleted successfully.`);
|
|
38
|
+
}
|
|
39
|
+
catch (error) {
|
|
40
|
+
this.handleError(error, 'delete organization');
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
//# sourceMappingURL=delete.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete.js","sourceRoot":"","sources":["../../../src/commands/org/delete.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,WAAW;IAChD,MAAM,CAAU,WAAW,GAAG,qCAAqC,CAAC;IAEpE,MAAM,CAAU,QAAQ,GAAG;QACzB,qCAAqC;QACrC,2CAA2C;KAC5C,CAAC;IAEF,MAAM,CAAU,IAAI,GAAG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E,qBAAqB,CAAC,CAAC;QACjD,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
2
|
+
export default class OrgGitLabRemove extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static args: {
|
|
6
|
+
org: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
7
|
+
};
|
|
8
|
+
static flags: {
|
|
9
|
+
yes: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
10
|
+
};
|
|
11
|
+
run(): Promise<void>;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=remove.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remove.d.ts","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/remove.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,WAAW;IACtD,OAAgB,WAAW,SAAoD;IAE/E,OAAgB,QAAQ,WAGtB;IAEF,OAAgB,IAAI;;MAKlB;IAEF,OAAgB,KAAK;;MAMnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CA6BlC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { Args, Flags } from '@oclif/core';
|
|
2
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
3
|
+
export default class OrgGitLabRemove extends BaseCommand {
|
|
4
|
+
static description = 'Remove GitLab integration from an organization';
|
|
5
|
+
static examples = [
|
|
6
|
+
'<%= config.bin %> org gitlab remove enspirit',
|
|
7
|
+
'<%= config.bin %> org gitlab remove enspirit --yes',
|
|
8
|
+
];
|
|
9
|
+
static args = {
|
|
10
|
+
org: Args.string({
|
|
11
|
+
description: 'Organization slug',
|
|
12
|
+
required: true,
|
|
13
|
+
}),
|
|
14
|
+
};
|
|
15
|
+
static flags = {
|
|
16
|
+
yes: Flags.boolean({
|
|
17
|
+
char: 'y',
|
|
18
|
+
description: 'Skip confirmation prompt',
|
|
19
|
+
default: false,
|
|
20
|
+
}),
|
|
21
|
+
};
|
|
22
|
+
async run() {
|
|
23
|
+
const { args, flags } = await this.parse(OrgGitLabRemove);
|
|
24
|
+
this.requireAuth();
|
|
25
|
+
try {
|
|
26
|
+
// Check if integration exists
|
|
27
|
+
await this.client.getGitLabIntegration(args.org);
|
|
28
|
+
if (!flags.yes) {
|
|
29
|
+
this.log(`About to remove GitLab integration for organization: ${args.org}`);
|
|
30
|
+
this.log('This will also delete all synced repositories.');
|
|
31
|
+
this.log('This action cannot be undone.');
|
|
32
|
+
this.log('');
|
|
33
|
+
this.log('To confirm, run again with --yes flag:');
|
|
34
|
+
this.log(` kiln org gitlab remove ${args.org} --yes`);
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
await this.client.deleteGitLabIntegration(args.org);
|
|
38
|
+
this.log(`GitLab integration removed from "${args.org}".`);
|
|
39
|
+
}
|
|
40
|
+
catch (error) {
|
|
41
|
+
const message = error instanceof Error ? error.message : 'Unknown error';
|
|
42
|
+
if (message.includes('not found') || message.includes('Not Found')) {
|
|
43
|
+
this.log(`No GitLab integration configured for "${args.org}".`);
|
|
44
|
+
}
|
|
45
|
+
else {
|
|
46
|
+
this.handleError(error, 'remove GitLab integration');
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=remove.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remove.js","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/remove.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,WAAW;IAC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G,CAAC,oCAAoC,IAAI,CAAC,GAAG,IAAI,CAAC,CAAC;QAC7D,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,OAAO,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,CAAC;YACzE,IAAI,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC;gBACnE,IAAI,CAAC,GAAG,CAAC,yCAAyC,IAAI,CAAC,GAAG,IAAI,CAAC,CAAC;YAClE,CAAC;iBAAM,CAAC;gBACN,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,2BAA2B,CAAC,CAAC;YACvD,CAAC;QACH,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
2
|
+
export default class OrgGitLabSetup extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static args: {
|
|
6
|
+
org: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
7
|
+
};
|
|
8
|
+
static flags: {
|
|
9
|
+
url: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
|
+
group: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
11
|
+
token: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
12
|
+
'default-branch': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
13
|
+
'default-commands': import("@oclif/core/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
14
|
+
};
|
|
15
|
+
run(): Promise<void>;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=setup.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/setup.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,WAAW;IACrD,OAAgB,WAAW,SAAsD;IAEjF,OAAgB,QAAQ,WAGtB;IAEF,OAAgB,IAAI;;MAKlB;IAEF,OAAgB,KAAK;;;;;;MA0BnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAyClC"}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { Args, Flags } from '@oclif/core';
|
|
2
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
3
|
+
export default class OrgGitLabSetup extends BaseCommand {
|
|
4
|
+
static description = 'Configure GitLab integration for an organization';
|
|
5
|
+
static examples = [
|
|
6
|
+
'<%= config.bin %> org gitlab setup enspirit --url https://gitlab.com --group enspirit --token glpat-xxxxx',
|
|
7
|
+
'<%= config.bin %> org gitlab setup enspirit --token glpat-xxxxx --default-commands "npm install" --default-commands "npm test"',
|
|
8
|
+
];
|
|
9
|
+
static args = {
|
|
10
|
+
org: Args.string({
|
|
11
|
+
description: 'Organization slug',
|
|
12
|
+
required: true,
|
|
13
|
+
}),
|
|
14
|
+
};
|
|
15
|
+
static flags = {
|
|
16
|
+
url: Flags.string({
|
|
17
|
+
char: 'u',
|
|
18
|
+
description: 'GitLab URL',
|
|
19
|
+
default: 'https://gitlab.com',
|
|
20
|
+
}),
|
|
21
|
+
group: Flags.string({
|
|
22
|
+
char: 'g',
|
|
23
|
+
description: 'GitLab group path (e.g., "enspirit" or "enspirit/subgroup")',
|
|
24
|
+
required: true,
|
|
25
|
+
}),
|
|
26
|
+
token: Flags.string({
|
|
27
|
+
char: 't',
|
|
28
|
+
description: 'GitLab personal access token',
|
|
29
|
+
required: true,
|
|
30
|
+
}),
|
|
31
|
+
'default-branch': Flags.string({
|
|
32
|
+
char: 'b',
|
|
33
|
+
description: 'Default branch for builds',
|
|
34
|
+
default: 'main',
|
|
35
|
+
}),
|
|
36
|
+
'default-commands': Flags.string({
|
|
37
|
+
char: 'c',
|
|
38
|
+
description: 'Default commands for builds (can be specified multiple times)',
|
|
39
|
+
multiple: true,
|
|
40
|
+
}),
|
|
41
|
+
};
|
|
42
|
+
async run() {
|
|
43
|
+
const { args, flags } = await this.parse(OrgGitLabSetup);
|
|
44
|
+
this.requireAuth();
|
|
45
|
+
try {
|
|
46
|
+
const integration = await this.client.configureGitLabIntegration(args.org, {
|
|
47
|
+
gitlabUrl: flags.url,
|
|
48
|
+
gitlabGroupPath: flags.group,
|
|
49
|
+
accessToken: flags.token,
|
|
50
|
+
defaultBranch: flags['default-branch'],
|
|
51
|
+
defaultCommands: flags['default-commands'],
|
|
52
|
+
enabled: true,
|
|
53
|
+
});
|
|
54
|
+
this.log('GitLab integration configured successfully!');
|
|
55
|
+
this.log('');
|
|
56
|
+
this.log('Configuration:');
|
|
57
|
+
this.log(` GitLab URL: ${integration.gitlabUrl}`);
|
|
58
|
+
if (integration.gitlabGroupPath) {
|
|
59
|
+
this.log(` Group: ${integration.gitlabGroupPath}`);
|
|
60
|
+
}
|
|
61
|
+
this.log(` Default Branch: ${integration.defaultBranch}`);
|
|
62
|
+
if (integration.defaultCommands?.length) {
|
|
63
|
+
this.log(` Default Commands: ${integration.defaultCommands.join(', ')}`);
|
|
64
|
+
}
|
|
65
|
+
this.log('');
|
|
66
|
+
this.log('Webhook Secret (save this for GitLab webhook setup):');
|
|
67
|
+
this.log(` ${integration.webhookSecret}`);
|
|
68
|
+
this.log('');
|
|
69
|
+
this.log('Webhook URL:');
|
|
70
|
+
this.log(` ${this.appConfig.url}/webhooks/gitlab/${args.org}`);
|
|
71
|
+
this.log('');
|
|
72
|
+
this.log('Next steps:');
|
|
73
|
+
this.log(' 1. Run `kiln org gitlab sync ${args.org}` to sync repositories');
|
|
74
|
+
this.log(' 2. Add the webhook URL to your GitLab group/project settings');
|
|
75
|
+
this.log(' - Events: Push events, Merge request events');
|
|
76
|
+
this.log(' - Secret token: Use the webhook secret above');
|
|
77
|
+
}
|
|
78
|
+
catch (error) {
|
|
79
|
+
this.handleError(error, 'configure GitLab integration');
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
//# sourceMappingURL=setup.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"setup.js","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/setup.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,WAAW;IACrD,MAAM,CAAU,WAAW,GAAG,kDAAkD,CAAC;IAEjF,MAAM,CAAU,QAAQ,GAAG;QACzB,2GAA2G;QAC3G,gIAAgI;KACjI,CAAC;IAEF,MAAM,CAAU,IAAI,GAAG;QACrB,GAAG,EAAE,IAAI,CAAC,MAAM,CAAC;YACf,WAAW,EAAE,mBAAmB;YAChC,QAAQ,EAAE,IAAI;SACf,CAAC;KACH,CAAC;IAEF,MAAM,CAAU,KAAK,GAAG;QACtB,GAAG,EAAE,KAAK,CAAC,MAAM,CAAC;YAChB,IAAI,EAAE,GAAG;YACT,WAAW,EAAE,YAAY;YACzB,OAAO,EAAE,oBAAoB;SAC9B,CAAC;QACF,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;YAClB,IAAI,EAAE,GAAG;YACT,WAAW,EAAE,6DAA6D;YAC1E,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC;YAClB,IAAI,EAAE,GAAG;YACT,WAAW,EAAE,8BAA8B;YAC3C,QAAQ,EAAE,IAAI;SACf,CAAC;QACF,gBAAgB,EAAE,KAAK,CAAC,MAAM,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xC,IAAI,CAAC,GAAG,CAAC,uBAAuB,WAAW,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YAC5E,CAAC;YACD,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YACb,IAAI,CAAC,GAAG,CAAC,sDAAsD,CAAC,CAAC;YACjE,IAAI,CAAC,GAAG,CAAC,KAAK,WAAW,CAAC,aAAa,EAAE,CAAC,CAAC;YAC3C,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YACb,IAAI,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;YACzB,IAAI,CAAC,GAAG,CAAC,KAAK,IAAI,CAAC,SAAS,CAAC,GAAG,oBAAoB,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC;YAChE,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YACb,IAAI,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC;YACxB,IAAI,CAAC,GAAG,CAAC,kEAAkE,CAAC,CAAC;YAC7E,IAAI,CAAC,GAAG,CAAC,gEAAgE,CAAC,CAAC;YAC3E,IAAI,CAAC,GAAG,CAAC,kDAAkD,CAAC,CAAC;YAC7D,IAAI,CAAC,GAAG,CAAC,mDAAmD,CAAC,CAAC;QAChE,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,8BAA8B,CAAC,CAAC;QAC1D,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
2
|
+
export default class OrgGitLabShow extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static args: {
|
|
6
|
+
org: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
7
|
+
};
|
|
8
|
+
run(): Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=show.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"show.d.ts","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/show.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,WAAW;IACpD,OAAgB,WAAW,SAA+D;IAE1F,OAAgB,QAAQ,WAEtB;IAEF,OAAgB,IAAI;;MAKlB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CAuClC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { Args } from '@oclif/core';
|
|
2
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
3
|
+
export default class OrgGitLabShow extends BaseCommand {
|
|
4
|
+
static description = 'Show GitLab integration configuration for an organization';
|
|
5
|
+
static examples = [
|
|
6
|
+
'<%= config.bin %> org gitlab show enspirit',
|
|
7
|
+
];
|
|
8
|
+
static args = {
|
|
9
|
+
org: Args.string({
|
|
10
|
+
description: 'Organization slug',
|
|
11
|
+
required: true,
|
|
12
|
+
}),
|
|
13
|
+
};
|
|
14
|
+
async run() {
|
|
15
|
+
const { args } = await this.parse(OrgGitLabShow);
|
|
16
|
+
this.requireAuth();
|
|
17
|
+
try {
|
|
18
|
+
const integration = await this.client.getGitLabIntegration(args.org);
|
|
19
|
+
this.log('GitLab Integration Configuration:');
|
|
20
|
+
this.log('');
|
|
21
|
+
this.log(` Status: ${integration.enabled ? 'enabled' : 'disabled'}`);
|
|
22
|
+
this.log(` GitLab URL: ${integration.gitlabUrl}`);
|
|
23
|
+
if (integration.gitlabGroupPath) {
|
|
24
|
+
this.log(` Group Path: ${integration.gitlabGroupPath}`);
|
|
25
|
+
}
|
|
26
|
+
this.log(` Default Branch: ${integration.defaultBranch}`);
|
|
27
|
+
if (integration.defaultCommands?.length) {
|
|
28
|
+
this.log(` Default Commands:`);
|
|
29
|
+
for (const cmd of integration.defaultCommands) {
|
|
30
|
+
this.log(` - ${cmd}`);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
this.log('');
|
|
34
|
+
this.log('Webhook Configuration:');
|
|
35
|
+
this.log(` URL: ${this.appConfig.url}/webhooks/gitlab/${args.org}`);
|
|
36
|
+
this.log(` Secret: ${integration.webhookSecret}`);
|
|
37
|
+
this.log('');
|
|
38
|
+
this.log(` Created: ${new Date(integration.createdAt).toLocaleString()}`);
|
|
39
|
+
}
|
|
40
|
+
catch (error) {
|
|
41
|
+
const message = error instanceof Error ? error.message : 'Unknown error';
|
|
42
|
+
if (message.includes('not found') || message.includes('Not Found')) {
|
|
43
|
+
this.log(`No GitLab integration configured for "${args.org}".`);
|
|
44
|
+
this.log('');
|
|
45
|
+
this.log('To configure GitLab integration, run:');
|
|
46
|
+
this.log(` kiln org gitlab setup ${args.org} --token <gitlab-token>`);
|
|
47
|
+
}
|
|
48
|
+
else {
|
|
49
|
+
this.handleError(error, 'get GitLab integration');
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
//# sourceMappingURL=show.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"show.js","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/show.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AACnC,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,WAAW;IACpD,MAAM,CAAU,WAAW,GAAG,2DAA2D,CAAC;IAE1F,MAAM,CAAU,QAAQ,GAAG;QACzB,4CAA4C;KAC7C,CAAC;IAEF,MAAM,CAAU,IAAI,GAAG;QACrB,GAAG,EAAE,IAAI,CAAC,MAAM,CAAC;YACf,WAAW,EAAE,mBAAmB;YAChC,QAAQ,EAAE,IAAI;SACf,CAAC;KACH,CAAC;IAEK,KAAK,CAAC,GAAG;QACd,MAAM,EAAE,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a,EAAE,CAAC,CAAC;YACnD,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YACb,IAAI,CAAC,GAAG,CAAC,cAAc,IAAI,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC,cAAc,EAAE,EAAE,CAAC,CAAC;QAC7E,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,OAAO,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,CAAC;YACzE,IAAI,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC;gBACnE,IAAI,CAAC,GAAG,CAAC,yCAAyC,IAAI,CAAC,GAAG,IAAI,CAAC,CAAC;gBAChE,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;gBACb,IAAI,CAAC,GAAG,CAAC,uCAAuC,CAAC,CAAC;gBAClD,IAAI,CAAC,GAAG,CAAC,2BAA2B,IAAI,CAAC,GAAG,yBAAyB,CAAC,CAAC;YACzE,CAAC;iBAAM,CAAC;gBACN,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,wBAAwB,CAAC,CAAC;YACpD,CAAC;QACH,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
2
|
+
export default class OrgGitLabSync extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static args: {
|
|
6
|
+
org: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
7
|
+
};
|
|
8
|
+
run(): Promise<void>;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=sync.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sync.d.ts","sourceRoot":"","sources":["../../../../src/commands/org/gitlab/sync.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAEvD,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,WAAW;IACpD,OAAgB,WAAW,SAAmC;IAE9D,OAAgB,QAAQ,WAEtB;IAEF,OAAgB,IAAI;;MAKlB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CA0BlC"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { Args } from '@oclif/core';
|
|
2
|
+
import { BaseCommand } from '../../../base-command.js';
|
|
3
|
+
export default class OrgGitLabSync extends BaseCommand {
|
|
4
|
+
static description = 'Sync repositories from GitLab';
|
|
5
|
+
static examples = [
|
|
6
|
+
'<%= config.bin %> org gitlab sync enspirit',
|
|
7
|
+
];
|
|
8
|
+
static args = {
|
|
9
|
+
org: Args.string({
|
|
10
|
+
description: 'Organization slug',
|
|
11
|
+
required: true,
|
|
12
|
+
}),
|
|
13
|
+
};
|
|
14
|
+
async run() {
|
|
15
|
+
const { args } = await this.parse(OrgGitLabSync);
|
|
16
|
+
this.requireAuth();
|
|
17
|
+
try {
|
|
18
|
+
this.log(`Syncing repositories for ${args.org}...`);
|
|
19
|
+
const result = await this.client.syncGitLabRepositories(args.org);
|
|
20
|
+
this.log('');
|
|
21
|
+
this.log(`Sync complete:`);
|
|
22
|
+
this.log(` Repositories synced: ${result.synced}`);
|
|
23
|
+
this.log(` Repositories removed: ${result.removed}`);
|
|
24
|
+
this.log('');
|
|
25
|
+
if (result.repositories.length > 0) {
|
|
26
|
+
this.log('Synced repositories:');
|
|
27
|
+
for (const repo of result.repositories) {
|
|
28
|
+
const status = repo.buildEnabled ? '(enabled)' : '(disabled)';
|
|
29
|
+
this.log(` - ${repo.fullPath} ${status}`);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
catch (error) {
|
|
34
|
+
this.handleError(error, 'sync repositories');
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
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;gBACnC,IAAI,CAAC,GAAG,CAAC,sBAAsB,CAAC,CAAC;gBACjC,KAAK,MAAM,IAAI,IAAI,MAAM,CAAC,YAAY,EAAE,CAAC;oBACvC,MAAM,MAAM,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,YAAY,CAAC;oBAC9D,IAAI,CAAC,GAAG,CAAC,OAAO,IAAI,CAAC,QAAQ,IAAI,MAAM,EAAE,CAAC,CAAC;gBAC7C,CAAC;YACH,CAAC;QACH,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,mBAAmB,CAAC,CAAC;QAC/C,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { BaseCommand } from '../../base-command.js';
|
|
2
|
+
export default class Org extends BaseCommand {
|
|
3
|
+
static description: string;
|
|
4
|
+
static examples: string[];
|
|
5
|
+
static flags: {
|
|
6
|
+
page: import("@oclif/core/interfaces").OptionFlag<number, import("@oclif/core/interfaces").CustomOptions>;
|
|
7
|
+
pageSize: import("@oclif/core/interfaces").OptionFlag<number, import("@oclif/core/interfaces").CustomOptions>;
|
|
8
|
+
};
|
|
9
|
+
run(): Promise<void>;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/commands/org/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,GAAI,SAAQ,WAAW;IAC1C,OAAgB,WAAW,SAAwB;IAEnD,OAAgB,QAAQ,WAGtB;IAEF,OAAgB,KAAK;;;MAWnB;IAEW,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CA2BlC"}
|