-
Notifications
You must be signed in to change notification settings - Fork 47
Expand file tree
/
Copy pathgenerate-cli-docs.ts
More file actions
110 lines (106 loc) · 3.14 KB
/
generate-cli-docs.ts
File metadata and controls
110 lines (106 loc) · 3.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
import { Commands } from './documentation-renderer/commands.js';
import type { CommandsInCategory } from './documentation-renderer/doc-building.js';
import { renderDocs } from './documentation-renderer/doc-building.js';
// This sets the maximum line length that will be rendered in the docs.
process.env.APIFY_CLI_MAX_LINE_WIDTH = '80';
const categories: Record<string, CommandsInCategory[]> = {
'auth': [
//
{ command: Commands.login },
{ command: Commands.logout },
{ command: Commands.info },
{ command: Commands.secrets },
{ command: Commands.secretsAdd },
{ command: Commands.secretsRm },
],
'actor-dev': [
//
{ command: Commands.create },
{ command: Commands.init },
{ command: Commands.run },
{ command: Commands.validateSchema },
],
'actor-basic': [
//
{ command: Commands.actors },
{ command: Commands.actorsLs },
{ command: Commands.actorsRm },
{ command: Commands.actor },
{ command: Commands.actorCalculateMemory },
{ command: Commands.actorCharge },
{ command: Commands.actorGetInput },
{ command: Commands.actorGetPublicUrl },
{ command: Commands.actorGetValue },
{ command: Commands.actorPushData },
{ command: Commands.actorSetValue },
],
'actor-deploy': [
//
{ command: Commands.actorsPush, aliases: [Commands.push] },
{ command: Commands.actorsPull, aliases: [Commands.pull] },
{ command: Commands.actorsCall, aliases: [Commands.call] },
{ command: Commands.actorsStart },
{ command: Commands.actorsInfo },
],
'actor-build': [
//
{ command: Commands.builds },
{ command: Commands.buildsCreate, aliases: [Commands.actorsBuild] },
{ command: Commands.buildsInfo },
{ command: Commands.buildsLog },
{ command: Commands.buildsLs },
{ command: Commands.buildsRm },
],
'actor-run': [
//
{ command: Commands.runs },
{ command: Commands.runsAbort },
{ command: Commands.runsInfo },
{ command: Commands.runsLog },
{ command: Commands.runsLs },
{ command: Commands.runsResurrect },
{ command: Commands.runsRm },
],
'general': [
//
{ command: Commands.help },
{ command: Commands.upgrade },
{ command: Commands.telemetry },
{ command: Commands.telemetryEnable },
{ command: Commands.telemetryDisable },
],
'dataset': [
//
{ command: Commands.datasets },
{ command: Commands.datasetsCreate },
{ command: Commands.datasetsGetItems },
{ command: Commands.datasetsInfo },
{ command: Commands.datasetsLs },
{ command: Commands.datasetsPushItems },
{ command: Commands.datasetsRename },
{ command: Commands.datasetsRm },
],
'keyval': [
//
{ command: Commands.keyValueStores },
{ command: Commands.keyValueStoresCreate },
{ command: Commands.keyValueStoresDeleteValue },
{ command: Commands.keyValueStoresGetValue },
{ command: Commands.keyValueStoresInfo },
{ command: Commands.keyValueStoresKeys },
{ command: Commands.keyValueStoresLs },
{ command: Commands.keyValueStoresRename },
{ command: Commands.keyValueStoresRm },
{ command: Commands.keyValueStoresSetValue },
],
'reqqueue': [
//
{ command: Commands.requestQueues },
],
'task': [
//
{ command: Commands.task },
{ command: Commands.taskRun },
],
};
await renderDocs(categories);