Skip to content

Commit 27ca0d5

Browse files
authored
Merge pull request #136 from sourcefuse/cli
docs(arc-api): add CLI page
2 parents 2b44b31 + 7d7becd commit 27ca0d5

File tree

2 files changed

+155
-0
lines changed

2 files changed

+155
-0
lines changed

docs/arc-api-docs/packages/cli.md

Lines changed: 152 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,152 @@
1+
@sourceloop/cli /
2+
3+
# @sourceloop-cli
4+
5+
<a style="position: relative; top: 10px;" href="https://sourcefuse.github.io/arc-docs/arc-api-docs" target="_blank"><img src="https://github.com/sourcefuse/loopback4-microservice-catalog/blob/master/docs/assets/logo-dark-bg.png?raw=true" alt="ARC By SourceFuse logo" title="ARC By SourceFuse" align="right" width="150" /></a>
6+
7+
This is a `sourceloop` based cli that provides commands to scaffold a monorepo, add extensions, facades and microservices to it.
8+
9+
## Installation
10+
11+
```shell
12+
npm install @sourceloop/cli
13+
```
14+
15+
After installation, use either sl or arc to run any of the CLI commands.
16+
17+
## Commands
18+
19+
<!-- commands -->
20+
- sl autocomplete
21+
- sl cdk
22+
- sl extension
23+
- sl help
24+
- sl mcp
25+
- sl microservice
26+
- sl scaffold
27+
- sl update
28+
29+
## sl autocomplete
30+
31+
Display autocomplete installation instructions
32+
33+
```
34+
USAGE
35+
$ sl autocomplete
36+
37+
OPTIONS
38+
-r, --refresh-cache
39+
40+
EXAMPLES
41+
$ sl autocomplete
42+
$ sl autocomplete bash
43+
$ sl autocomplete zsh
44+
$ sl autocomplete --refresh-cache
45+
```
46+
47+
## sl cdk
48+
49+
Add arc-cdk to your project
50+
51+
```
52+
USAGE
53+
$ sl cdk
54+
55+
OPTIONS
56+
-a, --applicationClassName
57+
-d, --dir
58+
-i, --iac=(lambda)
59+
-o, --overwriteDockerfile
60+
-p, --packageJsonName
61+
-r, --relativePathToApp
62+
```
63+
64+
## sl extension
65+
66+
Generate a local extension package in the packages folder.
67+
68+
```
69+
USAGE
70+
$ sl extension
71+
```
72+
73+
## sl help
74+
75+
Show help for a specific command.
76+
77+
```
78+
USAGE
79+
$ sl help
80+
```
81+
82+
## sl mcp
83+
84+
Run MCP server for CLI. This command is used internally.
85+
86+
```
87+
USAGE
88+
$ sl mcp
89+
90+
DESCRIPTION
91+
Command that runs an MCP server for the sourceloop CLI, this is not supposed to be run directly, but rather used by
92+
the MCP client to interact with the CLI commands.
93+
You can use it using the following MCP server configuration:
94+
"sourceloop": {
95+
"command": "npx",
96+
"args": ["@sourceloop/cli", "mcp"],
97+
"timeout": 300
98+
}
99+
```
100+
101+
## sl microservice
102+
103+
Add a microservice to services or facades folder. Supports custom and base microservice setup.
104+
105+
```
106+
USAGE
107+
$ sl microservice
108+
109+
OPTIONS
110+
-p, --uniquePrefix
111+
-s, --baseService
112+
--[no-]baseOnService
113+
--customMigrations
114+
--datasourceName
115+
--datasourceType=(postgres|mysql)
116+
--[no-]facade
117+
--help
118+
--includeMigrations
119+
--sequelize
120+
121+
```
122+
123+
## sl scaffold
124+
125+
Scaffold a new ARC-based monorepo with initial structure.
126+
127+
```
128+
USAGE
129+
$ sl scaffold
130+
131+
132+
OPTIONS
133+
--cwd
134+
--description
135+
--helmPath
136+
--help
137+
--integrateWithBackstage
138+
--issuePrefix
139+
--jenkinsfile
140+
--owner
141+
```
142+
143+
## sl update
144+
145+
Update the dependencies of a LoopBack project.
146+
147+
```
148+
USAGE
149+
$ sl update
150+
151+
```
152+
<!-- commandsstop -->
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
title: Packages
2+
nav:
3+
- CLI: cli.md

0 commit comments

Comments
 (0)