@iwonz/ywtc 0.0.0 → 2.0.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/.env.example +4 -0
- package/CHANGELOG.md +39 -0
- package/LICENSE +21 -0
- package/README.md +258 -1
- package/dist/adapters/confluence.d.ts +46 -0
- package/dist/adapters/confluence.js +187 -0
- package/dist/adapters/confluence.js.map +1 -0
- package/dist/adapters/factory.d.ts +3 -0
- package/dist/adapters/factory.js +11 -0
- package/dist/adapters/factory.js.map +1 -0
- package/dist/adapters/yandex.d.ts +45 -0
- package/dist/adapters/yandex.js +233 -0
- package/dist/adapters/yandex.js.map +1 -0
- package/dist/cli-arguments.d.ts +41 -0
- package/dist/cli-arguments.js +149 -0
- package/dist/cli-arguments.js.map +1 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +180 -0
- package/dist/cli.js.map +1 -0
- package/dist/clients/confluence-cloud.d.ts +45 -0
- package/dist/clients/confluence-cloud.js +261 -0
- package/dist/clients/confluence-cloud.js.map +1 -0
- package/dist/clients/confluence-factory.d.ts +3 -0
- package/dist/clients/confluence-factory.js +8 -0
- package/dist/clients/confluence-factory.js.map +1 -0
- package/dist/clients/confluence.d.ts +42 -0
- package/dist/clients/confluence.js +286 -0
- package/dist/clients/confluence.js.map +1 -0
- package/dist/clients/yandex-wiki.d.ts +35 -0
- package/dist/clients/yandex-wiki.js +255 -0
- package/dist/clients/yandex-wiki.js.map +1 -0
- package/dist/config.d.ts +52 -0
- package/dist/config.js +177 -0
- package/dist/config.js.map +1 -0
- package/dist/content-model.d.ts +12 -0
- package/dist/content-model.js +416 -0
- package/dist/content-model.js.map +1 -0
- package/dist/conversion.d.ts +43 -0
- package/dist/conversion.js +450 -0
- package/dist/conversion.js.map +1 -0
- package/dist/doctor.d.ts +24 -0
- package/dist/doctor.js +45 -0
- package/dist/doctor.js.map +1 -0
- package/dist/domain.d.ts +202 -0
- package/dist/domain.js +18 -0
- package/dist/domain.js.map +1 -0
- package/dist/filesystem-export.d.ts +53 -0
- package/dist/filesystem-export.js +243 -0
- package/dist/filesystem-export.js.map +1 -0
- package/dist/graph.d.ts +13 -0
- package/dist/graph.js +121 -0
- package/dist/graph.js.map +1 -0
- package/dist/http.d.ts +26 -0
- package/dist/http.js +100 -0
- package/dist/http.js.map +1 -0
- package/dist/index.d.ts +24 -0
- package/dist/index.js +25 -0
- package/dist/index.js.map +1 -0
- package/dist/input.d.ts +4 -0
- package/dist/input.js +56 -0
- package/dist/input.js.map +1 -0
- package/dist/locators.d.ts +24 -0
- package/dist/locators.js +84 -0
- package/dist/locators.js.map +1 -0
- package/dist/logger.d.ts +7 -0
- package/dist/logger.js +28 -0
- package/dist/logger.js.map +1 -0
- package/dist/migrator.d.ts +53 -0
- package/dist/migrator.js +669 -0
- package/dist/migrator.js.map +1 -0
- package/dist/rate-limiter.d.ts +12 -0
- package/dist/rate-limiter.js +31 -0
- package/dist/rate-limiter.js.map +1 -0
- package/dist/report.d.ts +101 -0
- package/dist/report.js +106 -0
- package/dist/report.js.map +1 -0
- package/dist/state.d.ts +119 -0
- package/dist/state.js +201 -0
- package/dist/state.js.map +1 -0
- package/dist/types.d.ts +197 -0
- package/dist/types.js +2 -0
- package/dist/types.js.map +1 -0
- package/dist/updater.d.ts +24 -0
- package/dist/updater.js +92 -0
- package/dist/updater.js.map +1 -0
- package/dist/version.d.ts +1 -0
- package/dist/version.js +8 -0
- package/dist/version.js.map +1 -0
- package/dist/workspace.d.ts +29 -0
- package/dist/workspace.js +157 -0
- package/dist/workspace.js.map +1 -0
- package/docs/assets/readme-header.png +0 -0
- package/package.json +108 -3
- package/ywtc.config.example.yaml +52 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import type { YandexConnectionProfile } from '../config.js';
|
|
2
|
+
import type { AdapterCapabilities, DestinationAdapter, DestinationContainer, DestinationPage, PageReference, SourceAdapter, SourcePage, SourceResource, UploadedResource } from '../domain.js';
|
|
3
|
+
import type { YandexWikiClient } from '../clients/yandex-wiki.js';
|
|
4
|
+
export declare class YandexAdapter implements SourceAdapter, DestinationAdapter {
|
|
5
|
+
readonly profile: YandexConnectionProfile;
|
|
6
|
+
private readonly client;
|
|
7
|
+
readonly kind: "yandex-wiki";
|
|
8
|
+
readonly capabilities: AdapterCapabilities;
|
|
9
|
+
constructor(profile: YandexConnectionProfile, client: YandexWikiClient);
|
|
10
|
+
preflight(): Promise<{
|
|
11
|
+
product: string;
|
|
12
|
+
warnings: string[];
|
|
13
|
+
}>;
|
|
14
|
+
resolvePage(locator: string): Promise<SourcePage>;
|
|
15
|
+
getPage(id: string): Promise<SourcePage>;
|
|
16
|
+
getDescendants(page: SourcePage): Promise<SourcePage[]>;
|
|
17
|
+
resolveReference(from: SourcePage, reference: PageReference): Promise<SourcePage | undefined>;
|
|
18
|
+
listResources(page: SourcePage): Promise<SourceResource[]>;
|
|
19
|
+
downloadResource(resource: SourceResource, destination: string): Promise<import("../types.js").DownloadedFile>;
|
|
20
|
+
resolveContainer(locator: string): Promise<DestinationContainer>;
|
|
21
|
+
private childSlug;
|
|
22
|
+
findChild(container: DestinationContainer | DestinationPage, title: string): Promise<DestinationPage | undefined>;
|
|
23
|
+
createPage(input: {
|
|
24
|
+
container: DestinationContainer | DestinationPage;
|
|
25
|
+
title: string;
|
|
26
|
+
body: string;
|
|
27
|
+
}): Promise<DestinationPage>;
|
|
28
|
+
updatePage(input: {
|
|
29
|
+
page: DestinationPage;
|
|
30
|
+
title: string;
|
|
31
|
+
body: string;
|
|
32
|
+
expectedFingerprint?: string;
|
|
33
|
+
}): Promise<DestinationPage>;
|
|
34
|
+
uploadResource(input: {
|
|
35
|
+
page: DestinationPage;
|
|
36
|
+
name: string;
|
|
37
|
+
filePath: string;
|
|
38
|
+
size?: number;
|
|
39
|
+
mimeType?: string;
|
|
40
|
+
}): Promise<UploadedResource>;
|
|
41
|
+
listUploadedResources(page: DestinationPage): Promise<UploadedResource[]>;
|
|
42
|
+
verifyPage(page: DestinationPage): Promise<DestinationPage>;
|
|
43
|
+
renderPageReference(page: DestinationPage, label: string, anchor?: string): string;
|
|
44
|
+
renderResourceReference(resource: UploadedResource, label: string, image: boolean): string;
|
|
45
|
+
}
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
import { createHash } from 'node:crypto';
|
|
2
|
+
import { stat } from 'node:fs/promises';
|
|
3
|
+
import { extractPageReferences, resolveYandexReferenceSlug } from '../content-model.js';
|
|
4
|
+
import { HttpRequestError } from '../http.js';
|
|
5
|
+
import { normalizeWikiSlug, safeFilename } from '../input.js';
|
|
6
|
+
const capabilities = {
|
|
7
|
+
readPages: true,
|
|
8
|
+
readHierarchy: true,
|
|
9
|
+
readResources: true,
|
|
10
|
+
writePages: true,
|
|
11
|
+
writeResources: true,
|
|
12
|
+
verifyWrites: true,
|
|
13
|
+
};
|
|
14
|
+
function pageUrl(profile, slug) {
|
|
15
|
+
return new URL(`${normalizeWikiSlug(slug)}/`, `${profile.webUrl}/`).toString();
|
|
16
|
+
}
|
|
17
|
+
function parentId(page) {
|
|
18
|
+
return [...(page.breadcrumbs ?? [])].reverse().find((item) => item.id !== undefined && item.id !== page.id)?.id?.toString();
|
|
19
|
+
}
|
|
20
|
+
function canonical(profile, id) {
|
|
21
|
+
return `${profile.name}:yandex-wiki:${id}`;
|
|
22
|
+
}
|
|
23
|
+
function sourcePage(profile, page) {
|
|
24
|
+
const rawContent = page.content ?? '';
|
|
25
|
+
const parent = parentId(page);
|
|
26
|
+
return {
|
|
27
|
+
provider: 'yandex-wiki',
|
|
28
|
+
profile: profile.name,
|
|
29
|
+
id: String(page.id),
|
|
30
|
+
canonicalId: canonical(profile, page.id),
|
|
31
|
+
title: page.title || normalizeWikiSlug(page.slug).split('/').at(-1) || `Page ${page.id}`,
|
|
32
|
+
locator: normalizeWikiSlug(page.slug),
|
|
33
|
+
url: pageUrl(profile, page.slug),
|
|
34
|
+
...(parent ? { parentId: parent } : {}),
|
|
35
|
+
rawContent,
|
|
36
|
+
rawFormat: 'yfm',
|
|
37
|
+
...(page.attributes?.modified_at ? { modifiedAt: page.attributes.modified_at, version: page.attributes.modified_at } : {}),
|
|
38
|
+
references: extractPageReferences(rawContent, 'yfm'),
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
function destinationPage(profile, page) {
|
|
42
|
+
const fingerprint = createHash('sha256').update(`${page.title}\0${page.content ?? ''}\0${page.attributes?.modified_at ?? ''}`).digest('hex');
|
|
43
|
+
return {
|
|
44
|
+
provider: 'yandex-wiki',
|
|
45
|
+
profile: profile.name,
|
|
46
|
+
id: String(page.id),
|
|
47
|
+
canonicalId: canonical(profile, page.id),
|
|
48
|
+
title: page.title,
|
|
49
|
+
url: pageUrl(profile, page.slug),
|
|
50
|
+
locator: normalizeWikiSlug(page.slug),
|
|
51
|
+
...(page.attributes?.modified_at ? { version: page.attributes.modified_at } : {}),
|
|
52
|
+
fingerprint,
|
|
53
|
+
contentLength: Buffer.byteLength(page.content ?? ''),
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
function destinationContainer(profile, page) {
|
|
57
|
+
return {
|
|
58
|
+
provider: 'yandex-wiki',
|
|
59
|
+
profile: profile.name,
|
|
60
|
+
id: String(page.id),
|
|
61
|
+
canonicalId: canonical(profile, page.id),
|
|
62
|
+
title: page.title,
|
|
63
|
+
url: pageUrl(profile, page.slug),
|
|
64
|
+
locator: normalizeWikiSlug(page.slug),
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
function slugSegment(value) {
|
|
68
|
+
const normalized = value.normalize('NFKD').toLocaleLowerCase()
|
|
69
|
+
.replace(/[^\p{L}\p{N}]+/gu, '-')
|
|
70
|
+
.replace(/^-+|-+$/g, '');
|
|
71
|
+
return normalized || 'page';
|
|
72
|
+
}
|
|
73
|
+
function attachmentSize(value) {
|
|
74
|
+
if (typeof value === 'number')
|
|
75
|
+
return Number.isFinite(value) ? Math.round(value) : undefined;
|
|
76
|
+
const match = value.trim().match(/^(\d+(?:[.,]\d+)?)\s*(B|KB|KIB|MB|MIB|GB|GIB)?$/i);
|
|
77
|
+
if (!match?.[1])
|
|
78
|
+
return undefined;
|
|
79
|
+
const number = Number(match[1].replace(',', '.'));
|
|
80
|
+
const unit = match[2]?.toLocaleUpperCase() ?? 'B';
|
|
81
|
+
const multiplier = unit === 'KB' ? 1_000
|
|
82
|
+
: unit === 'KIB' ? 1_024
|
|
83
|
+
: unit === 'MB' ? 1_000_000
|
|
84
|
+
: unit === 'MIB' ? 1_048_576
|
|
85
|
+
: unit === 'GB' ? 1_000_000_000
|
|
86
|
+
: unit === 'GIB' ? 1_073_741_824
|
|
87
|
+
: 1;
|
|
88
|
+
return Number.isFinite(number) ? Math.round(number * multiplier) : undefined;
|
|
89
|
+
}
|
|
90
|
+
function attachmentResource(profile, page, attachment) {
|
|
91
|
+
const numericSize = attachmentSize(attachment.size);
|
|
92
|
+
return {
|
|
93
|
+
provider: 'yandex-wiki',
|
|
94
|
+
id: String(attachment.id),
|
|
95
|
+
pageId: page.id,
|
|
96
|
+
name: attachment.name,
|
|
97
|
+
...(numericSize !== undefined ? { size: numericSize } : {}),
|
|
98
|
+
...(attachment.mimetype ? { mimeType: attachment.mimetype } : {}),
|
|
99
|
+
...(attachment.download_url ? { downloadUrl: attachment.download_url } : {}),
|
|
100
|
+
kind: attachment.has_preview ? 'image' : 'attachment',
|
|
101
|
+
metadata: { profile: profile.name },
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
export class YandexAdapter {
|
|
105
|
+
profile;
|
|
106
|
+
client;
|
|
107
|
+
kind = 'yandex-wiki';
|
|
108
|
+
capabilities = capabilities;
|
|
109
|
+
constructor(profile, client) {
|
|
110
|
+
this.profile = profile;
|
|
111
|
+
this.client = client;
|
|
112
|
+
}
|
|
113
|
+
async preflight() {
|
|
114
|
+
return { product: 'Yandex Wiki Public API v1', warnings: [] };
|
|
115
|
+
}
|
|
116
|
+
async resolvePage(locator) {
|
|
117
|
+
const trimmed = locator.trim();
|
|
118
|
+
if (/^\d+$/.test(trimmed))
|
|
119
|
+
return sourcePage(this.profile, await this.client.getPageById(Number(trimmed)));
|
|
120
|
+
let slug = trimmed;
|
|
121
|
+
try {
|
|
122
|
+
const url = new URL(trimmed);
|
|
123
|
+
const base = new URL(this.profile.webUrl);
|
|
124
|
+
if (url.origin !== base.origin)
|
|
125
|
+
throw new Error(`Yandex Wiki source host must match ${base.origin}`);
|
|
126
|
+
slug = url.pathname.slice(base.pathname.replace(/\/+$/, '').length);
|
|
127
|
+
}
|
|
128
|
+
catch (error) {
|
|
129
|
+
if (/^[a-z][a-z\d+.-]*:\/\//i.test(trimmed))
|
|
130
|
+
throw error;
|
|
131
|
+
}
|
|
132
|
+
return sourcePage(this.profile, await this.client.getPageBySlug(normalizeWikiSlug(slug)));
|
|
133
|
+
}
|
|
134
|
+
async getPage(id) {
|
|
135
|
+
return sourcePage(this.profile, await this.client.getPageById(Number(id)));
|
|
136
|
+
}
|
|
137
|
+
async getDescendants(page) {
|
|
138
|
+
const identities = await this.client.getDescendants(Number(page.id));
|
|
139
|
+
return Promise.all(identities.map(async (identity) => sourcePage(this.profile, await this.client.getPageById(identity.id))));
|
|
140
|
+
}
|
|
141
|
+
async resolveReference(from, reference) {
|
|
142
|
+
if (reference.kind !== 'page' || !reference.href)
|
|
143
|
+
return undefined;
|
|
144
|
+
const slug = resolveYandexReferenceSlug(from, reference.href);
|
|
145
|
+
if (!slug)
|
|
146
|
+
return undefined;
|
|
147
|
+
return sourcePage(this.profile, await this.client.getPageBySlug(slug));
|
|
148
|
+
}
|
|
149
|
+
async listResources(page) {
|
|
150
|
+
const [attachments, grids] = await Promise.all([
|
|
151
|
+
this.client.getAttachments(Number(page.id)),
|
|
152
|
+
this.client.getPageGrids(Number(page.id)),
|
|
153
|
+
]);
|
|
154
|
+
const attachmentItems = attachments.filter((attachment) => attachment.is_downloadable).map((attachment) => attachmentResource(this.profile, page, attachment));
|
|
155
|
+
const gridItems = await Promise.all(grids.map(async (summary) => ({
|
|
156
|
+
provider: 'yandex-wiki',
|
|
157
|
+
id: summary.id,
|
|
158
|
+
pageId: page.id,
|
|
159
|
+
name: `${safeFilename(summary.title)}.grid.json`,
|
|
160
|
+
kind: 'grid',
|
|
161
|
+
metadata: { grid: await this.client.getGrid(summary.id) },
|
|
162
|
+
})));
|
|
163
|
+
return [...attachmentItems, ...gridItems];
|
|
164
|
+
}
|
|
165
|
+
downloadResource(resource, destination) {
|
|
166
|
+
if (resource.kind === 'grid')
|
|
167
|
+
throw new Error(`Grid ${resource.name} is normalized as page content and is not downloadable`);
|
|
168
|
+
return this.client.download(Number(resource.pageId), Number(resource.id), destination);
|
|
169
|
+
}
|
|
170
|
+
async resolveContainer(locator) {
|
|
171
|
+
const page = await this.resolvePage(locator);
|
|
172
|
+
const details = await this.client.getPageById(Number(page.id));
|
|
173
|
+
if (details.attributes?.is_readonly) {
|
|
174
|
+
throw new Error(`Yandex Wiki destination page ${details.slug} is read-only for the current user`);
|
|
175
|
+
}
|
|
176
|
+
return destinationContainer(this.profile, details);
|
|
177
|
+
}
|
|
178
|
+
childSlug(container, title) {
|
|
179
|
+
if (!container.locator)
|
|
180
|
+
throw new Error(`Yandex Wiki destination ${container.id} is missing a slug`);
|
|
181
|
+
return `${normalizeWikiSlug(container.locator)}/${slugSegment(title)}`;
|
|
182
|
+
}
|
|
183
|
+
async findChild(container, title) {
|
|
184
|
+
try {
|
|
185
|
+
return destinationPage(this.profile, await this.client.getPageBySlug(this.childSlug(container, title)));
|
|
186
|
+
}
|
|
187
|
+
catch (error) {
|
|
188
|
+
if (error instanceof HttpRequestError && error.status === 404)
|
|
189
|
+
return undefined;
|
|
190
|
+
throw error;
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
async createPage(input) {
|
|
194
|
+
const created = await this.client.createPage({ slug: this.childSlug(input.container, input.title), title: input.title, content: input.body });
|
|
195
|
+
return destinationPage(this.profile, created);
|
|
196
|
+
}
|
|
197
|
+
async updatePage(input) {
|
|
198
|
+
if (input.expectedFingerprint) {
|
|
199
|
+
const current = destinationPage(this.profile, await this.client.getPageById(Number(input.page.id)));
|
|
200
|
+
if (current.fingerprint !== input.expectedFingerprint)
|
|
201
|
+
throw new Error(`Destination conflict for Yandex Wiki page ${input.page.id}: content changed since the last verified run`);
|
|
202
|
+
}
|
|
203
|
+
return destinationPage(this.profile, await this.client.updatePage({ id: Number(input.page.id), title: input.title, content: input.body }));
|
|
204
|
+
}
|
|
205
|
+
async uploadResource(input) {
|
|
206
|
+
const size = input.size ?? (await stat(input.filePath)).size;
|
|
207
|
+
const attachment = await this.client.uploadAttachment({ pageId: Number(input.page.id), filename: input.name, path: input.filePath, size });
|
|
208
|
+
return { id: String(attachment.id), name: attachment.name, size, ...(attachment.download_url ? { url: attachment.download_url } : {}) };
|
|
209
|
+
}
|
|
210
|
+
async listUploadedResources(page) {
|
|
211
|
+
const attachments = await this.client.getAttachments(Number(page.id));
|
|
212
|
+
return attachments.map((attachment) => {
|
|
213
|
+
const size = attachmentSize(attachment.size);
|
|
214
|
+
return {
|
|
215
|
+
id: String(attachment.id),
|
|
216
|
+
name: attachment.name,
|
|
217
|
+
...(size !== undefined ? { size } : {}),
|
|
218
|
+
...(attachment.download_url ? { url: attachment.download_url } : {}),
|
|
219
|
+
};
|
|
220
|
+
});
|
|
221
|
+
}
|
|
222
|
+
async verifyPage(page) {
|
|
223
|
+
return destinationPage(this.profile, await this.client.getPageById(Number(page.id)));
|
|
224
|
+
}
|
|
225
|
+
renderPageReference(page, label, anchor) {
|
|
226
|
+
return `[${label}](${page.url}${anchor ? `#${anchor}` : ''})`;
|
|
227
|
+
}
|
|
228
|
+
renderResourceReference(resource, label, image) {
|
|
229
|
+
const href = resource.url ?? resource.name;
|
|
230
|
+
return image ? `` : `[${label}](${href})`;
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
//# sourceMappingURL=yandex.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"yandex.js","sourceRoot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0,0 +1,41 @@
|
|
|
1
|
+
import { Command } from '@commander-js/extra-typings';
|
|
2
|
+
import type { ExportFormat, TransferScope } from './domain.js';
|
|
3
|
+
export type CliCommand = {
|
|
4
|
+
command: 'help';
|
|
5
|
+
topic?: 'init' | 'doctor' | 'migrate' | 'update';
|
|
6
|
+
} | {
|
|
7
|
+
command: 'version';
|
|
8
|
+
} | {
|
|
9
|
+
command: 'init';
|
|
10
|
+
workdir?: string;
|
|
11
|
+
} | {
|
|
12
|
+
command: 'doctor';
|
|
13
|
+
workdir?: string;
|
|
14
|
+
source?: string;
|
|
15
|
+
destination?: string;
|
|
16
|
+
sourceProfile?: string;
|
|
17
|
+
destinationProfile?: string;
|
|
18
|
+
scope: TransferScope;
|
|
19
|
+
format?: ExportFormat;
|
|
20
|
+
} | {
|
|
21
|
+
command: 'migrate';
|
|
22
|
+
source: string;
|
|
23
|
+
destination: string;
|
|
24
|
+
sourceProfile?: string;
|
|
25
|
+
destinationProfile?: string;
|
|
26
|
+
scope: TransferScope;
|
|
27
|
+
format?: ExportFormat;
|
|
28
|
+
archive: boolean;
|
|
29
|
+
workdir?: string;
|
|
30
|
+
dryRun: boolean;
|
|
31
|
+
fresh: boolean;
|
|
32
|
+
concurrency?: number;
|
|
33
|
+
stateFilename?: string;
|
|
34
|
+
} | {
|
|
35
|
+
command: 'update';
|
|
36
|
+
install: boolean;
|
|
37
|
+
via?: 'npm' | 'brew';
|
|
38
|
+
};
|
|
39
|
+
export declare function createCliProgram(onCommand?: (command: CliCommand) => void): Command;
|
|
40
|
+
export declare function parseCliArguments(argv: string[]): CliCommand;
|
|
41
|
+
export declare function cliHelp(topic?: 'init' | 'doctor' | 'migrate' | 'update'): string;
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { Command, Option } from '@commander-js/extra-typings';
|
|
2
|
+
import { packageVersion } from './version.js';
|
|
3
|
+
function nonEmpty(value, option) {
|
|
4
|
+
if (value === undefined)
|
|
5
|
+
return undefined;
|
|
6
|
+
const trimmed = value.trim();
|
|
7
|
+
if (!trimmed)
|
|
8
|
+
throw new Error(`${option} must be non-empty.`);
|
|
9
|
+
return trimmed;
|
|
10
|
+
}
|
|
11
|
+
function concurrency(value) {
|
|
12
|
+
const parsed = Number(value);
|
|
13
|
+
if (!Number.isInteger(parsed) || parsed < 1 || parsed > 64)
|
|
14
|
+
throw new Error('--concurrency must be an integer between 1 and 64.');
|
|
15
|
+
return parsed;
|
|
16
|
+
}
|
|
17
|
+
export function createCliProgram(onCommand = () => undefined) {
|
|
18
|
+
const program = new Command()
|
|
19
|
+
.name('ywtc')
|
|
20
|
+
.description('Loss-aware Yandex Wiki and Confluence transfer CLI')
|
|
21
|
+
.version(packageVersion(), '-v, --version')
|
|
22
|
+
.showHelpAfterError('(run ywtc --help for usage)')
|
|
23
|
+
.showSuggestionAfterError(true);
|
|
24
|
+
program.command('init')
|
|
25
|
+
.description('Create or repair a workspace without overwriting data')
|
|
26
|
+
.option('--workdir <path>', 'workspace to initialize')
|
|
27
|
+
.action((options) => {
|
|
28
|
+
const workdir = nonEmpty(options.workdir, '--workdir');
|
|
29
|
+
onCommand({ command: 'init', ...(workdir ? { workdir } : {}) });
|
|
30
|
+
});
|
|
31
|
+
program.command('doctor')
|
|
32
|
+
.description('Validate profiles and optionally perform read-only endpoint preflight')
|
|
33
|
+
.option('--workdir <path>', 'workspace to inspect')
|
|
34
|
+
.option('--source <locator>', 'source page URL, ID, or slug')
|
|
35
|
+
.option('--destination <locator>', 'destination page URL, ID, slug, or directory')
|
|
36
|
+
.option('--source-profile <name>', 'named source connection')
|
|
37
|
+
.option('--destination-profile <name>', 'named destination connection')
|
|
38
|
+
.addOption(new Option('--scope <scope>', 'selection scope').choices(['page', 'subtree', 'linked']).default('subtree'))
|
|
39
|
+
.addOption(new Option('--format <format>', 'filesystem format').choices(['markdown', 'html']))
|
|
40
|
+
.action((options) => {
|
|
41
|
+
const source = nonEmpty(options.source, '--source');
|
|
42
|
+
const destination = nonEmpty(options.destination, '--destination');
|
|
43
|
+
const workdir = nonEmpty(options.workdir, '--workdir');
|
|
44
|
+
const sourceProfile = nonEmpty(options.sourceProfile, '--source-profile');
|
|
45
|
+
const destinationProfile = nonEmpty(options.destinationProfile, '--destination-profile');
|
|
46
|
+
if (Boolean(source) !== Boolean(destination))
|
|
47
|
+
throw new Error('doctor requires both --source and --destination for API preflight, or neither for local checks.');
|
|
48
|
+
onCommand({
|
|
49
|
+
command: 'doctor',
|
|
50
|
+
scope: options.scope,
|
|
51
|
+
...(workdir ? { workdir } : {}),
|
|
52
|
+
...(source && destination ? { source, destination } : {}),
|
|
53
|
+
...(sourceProfile ? { sourceProfile } : {}),
|
|
54
|
+
...(destinationProfile ? { destinationProfile } : {}),
|
|
55
|
+
...(options.format ? { format: options.format } : {}),
|
|
56
|
+
});
|
|
57
|
+
});
|
|
58
|
+
program.command('migrate')
|
|
59
|
+
.description('Transfer or export a page graph')
|
|
60
|
+
.requiredOption('--source <locator>', 'source page URL, ID, or slug')
|
|
61
|
+
.requiredOption('--destination <locator>', 'destination page URL, ID, slug, or directory')
|
|
62
|
+
.option('--source-profile <name>', 'named source connection')
|
|
63
|
+
.option('--destination-profile <name>', 'named destination connection')
|
|
64
|
+
.addOption(new Option('--scope <scope>', 'selection scope').choices(['page', 'subtree', 'linked']).default('subtree'))
|
|
65
|
+
.addOption(new Option('--format <format>', 'filesystem format').choices(['markdown', 'html']))
|
|
66
|
+
.option('--archive', 'also create a ZIP for filesystem output', false)
|
|
67
|
+
.option('--workdir <path>', 'workspace (marked CWD, then ~/.ywtc)')
|
|
68
|
+
.option('--dry-run', 'discover and render without destination writes', false)
|
|
69
|
+
.option('--fresh', 'ignore mappings and preserve existing live state as a backup', false)
|
|
70
|
+
.option('--concurrency <n>', 'orchestration concurrency from 1 to 64', concurrency)
|
|
71
|
+
.option('--state <path>', 'state path inside workdir')
|
|
72
|
+
.action((options) => {
|
|
73
|
+
const source = nonEmpty(options.source, '--source');
|
|
74
|
+
const destination = nonEmpty(options.destination, '--destination');
|
|
75
|
+
const sourceProfile = nonEmpty(options.sourceProfile, '--source-profile');
|
|
76
|
+
const destinationProfile = nonEmpty(options.destinationProfile, '--destination-profile');
|
|
77
|
+
const workdir = nonEmpty(options.workdir, '--workdir');
|
|
78
|
+
const stateFilename = nonEmpty(options.state, '--state');
|
|
79
|
+
if (options.archive && !options.format)
|
|
80
|
+
throw new Error('--archive requires --format markdown|html and a directory destination.');
|
|
81
|
+
if (options.format && /^https?:\/\//i.test(destination))
|
|
82
|
+
throw new Error('--format cannot be used with a remote HTTP(S) destination.');
|
|
83
|
+
onCommand({
|
|
84
|
+
command: 'migrate',
|
|
85
|
+
source,
|
|
86
|
+
destination,
|
|
87
|
+
scope: options.scope,
|
|
88
|
+
archive: options.archive,
|
|
89
|
+
dryRun: options.dryRun,
|
|
90
|
+
fresh: options.fresh,
|
|
91
|
+
...(sourceProfile ? { sourceProfile } : {}),
|
|
92
|
+
...(destinationProfile ? { destinationProfile } : {}),
|
|
93
|
+
...(options.format ? { format: options.format } : {}),
|
|
94
|
+
...(workdir ? { workdir } : {}),
|
|
95
|
+
...(options.concurrency !== undefined ? { concurrency: options.concurrency } : {}),
|
|
96
|
+
...(stateFilename ? { stateFilename } : {}),
|
|
97
|
+
});
|
|
98
|
+
});
|
|
99
|
+
program.command('update')
|
|
100
|
+
.description('Check for a newer release and optionally update a safe installation')
|
|
101
|
+
.option('--install', 'install after checking', false)
|
|
102
|
+
.addOption(new Option('--via <channel>', 'force a compatible installation channel').choices(['npm', 'brew']))
|
|
103
|
+
.action((options) => onCommand({
|
|
104
|
+
command: 'update',
|
|
105
|
+
install: options.install,
|
|
106
|
+
...(options.via ? { via: options.via } : {}),
|
|
107
|
+
}));
|
|
108
|
+
return program;
|
|
109
|
+
}
|
|
110
|
+
export function parseCliArguments(argv) {
|
|
111
|
+
if (argv.includes('--target'))
|
|
112
|
+
throw new Error('--target was removed in ywtc 2.0. Use --destination.');
|
|
113
|
+
if (argv.includes('--single-page'))
|
|
114
|
+
throw new Error('--single-page was removed in ywtc 2.0. Use --scope page.');
|
|
115
|
+
if (argv.length === 0 || (argv.length === 1 && ['--help', '-h'].includes(argv[0])))
|
|
116
|
+
return { command: 'help' };
|
|
117
|
+
if (argv.length === 1 && ['--version', '-v'].includes(argv[0]))
|
|
118
|
+
return { command: 'version' };
|
|
119
|
+
const helpIndex = argv.findIndex((value) => ['--help', '-h'].includes(value));
|
|
120
|
+
if (helpIndex >= 0) {
|
|
121
|
+
const topic = argv[0];
|
|
122
|
+
return ['init', 'doctor', 'migrate', 'update'].includes(topic ?? '')
|
|
123
|
+
? { command: 'help', topic: topic }
|
|
124
|
+
: { command: 'help' };
|
|
125
|
+
}
|
|
126
|
+
let parsed;
|
|
127
|
+
const output = [];
|
|
128
|
+
const program = createCliProgram((command) => { parsed = command; });
|
|
129
|
+
program.exitOverride();
|
|
130
|
+
program.configureOutput({ writeOut: (value) => output.push(value), writeErr: (value) => output.push(value) });
|
|
131
|
+
try {
|
|
132
|
+
program.parse(['node', 'ywtc', ...argv], { from: 'node' });
|
|
133
|
+
}
|
|
134
|
+
catch (error) {
|
|
135
|
+
const message = output.join('').trim();
|
|
136
|
+
throw new Error(message || (error instanceof Error ? error.message : String(error)));
|
|
137
|
+
}
|
|
138
|
+
if (!parsed)
|
|
139
|
+
throw new Error('No command was selected. Run "ywtc --help".');
|
|
140
|
+
return parsed;
|
|
141
|
+
}
|
|
142
|
+
export function cliHelp(topic) {
|
|
143
|
+
const program = createCliProgram();
|
|
144
|
+
if (!topic)
|
|
145
|
+
return program.helpInformation();
|
|
146
|
+
const command = program.commands.find((candidate) => candidate.name() === topic);
|
|
147
|
+
return command?.helpInformation() ?? program.helpInformation();
|
|
148
|
+
}
|
|
149
|
+
//# sourceMappingURL=cli-arguments.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli-arguments.js","sourceRoot":"","sources":["../src/cli-arguments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC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