Skip to content

Commit 8a129c4

Browse files
Merge pull request #27 from AnswerDotAI/clarify-excluded-files-in-deploy
fix deploy cmd docstring to clarify exclusions of dot files
2 parents ee3a22c + cc8bf96 commit 8a129c4

3 files changed

Lines changed: 70 additions & 70 deletions

File tree

nbs/00_core.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@
338338
"def deploy(\n",
339339
" path:Path=Path('.'), # Path to project\n",
340340
" app_id:str=None): # Overrides the .plash file in project root if provided\n",
341-
" 'Ship your app to production'\n",
341+
" \"Deploy app to production (ignores paths starting with '.')\"\n",
342342
" print('Initializing deployment...')\n",
343343
" if app_id == '': print('Error: App ID cannot be an empty string'); return\n",
344344
" if not path.is_dir(): print(\"Error: Path should point to the project directory\"); return\n",

nbs/reference/00_cli.ipynb

Lines changed: 68 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@
3939
"name": "stdout",
4040
"output_type": "stream",
4141
"text": [
42-
"usage: plash_login [-h]\n",
43-
"\n",
44-
"Authenticate CLI with server and save config\n",
45-
"\n",
46-
"options:\n",
47-
" -h, --help show this help message and exit\n",
42+
"usage: plash_login [-h]\r\n",
43+
"\r\n",
44+
"Authenticate CLI with server and save config\r\n",
45+
"\r\n",
46+
"options:\r\n",
47+
" -h, --help show this help message and exit\r\n",
4848
"\n"
4949
]
5050
}
@@ -72,14 +72,14 @@
7272
"name": "stdout",
7373
"output_type": "stream",
7474
"text": [
75-
"usage: plash_deploy [-h] [--path PATH] [--app_id APP_ID]\n",
76-
"\n",
77-
"Ship your app to production\n",
78-
"\n",
79-
"options:\n",
80-
" -h, --help show this help message and exit\n",
81-
" --path PATH Path to project (default: .)\n",
82-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
75+
"usage: plash_deploy [-h] [--path PATH] [--app_id APP_ID]\r\n",
76+
"\r\n",
77+
"Deploy app to production (ignores paths starting with '.')\r\n",
78+
"\r\n",
79+
"options:\r\n",
80+
" -h, --help show this help message and exit\r\n",
81+
" --path PATH Path to project (default: .)\r\n",
82+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
8383
"\n"
8484
]
8585
}
@@ -107,14 +107,14 @@
107107
"name": "stdout",
108108
"output_type": "stream",
109109
"text": [
110-
"usage: plash_view [-h] [--path PATH] [--app_id APP_ID]\n",
111-
"\n",
112-
"Open your app in the browser\n",
113-
"\n",
114-
"options:\n",
115-
" -h, --help show this help message and exit\n",
116-
" --path PATH Path to project directory (default: .)\n",
117-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
110+
"usage: plash_view [-h] [--path PATH] [--app_id APP_ID]\r\n",
111+
"\r\n",
112+
"Open your app in the browser\r\n",
113+
"\r\n",
114+
"options:\r\n",
115+
" -h, --help show this help message and exit\r\n",
116+
" --path PATH Path to project directory (default: .)\r\n",
117+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
118118
"\n"
119119
]
120120
}
@@ -142,14 +142,14 @@
142142
"name": "stdout",
143143
"output_type": "stream",
144144
"text": [
145-
"usage: plash_start [-h] [--path PATH] [--app_id APP_ID]\n",
146-
"\n",
147-
"Access the '/start' endpoint for your app\n",
148-
"\n",
149-
"options:\n",
150-
" -h, --help show this help message and exit\n",
151-
" --path PATH Path to project (default: .)\n",
152-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
145+
"usage: plash_start [-h] [--path PATH] [--app_id APP_ID]\r\n",
146+
"\r\n",
147+
"Access the '/start' endpoint for your app\r\n",
148+
"\r\n",
149+
"options:\r\n",
150+
" -h, --help show this help message and exit\r\n",
151+
" --path PATH Path to project (default: .)\r\n",
152+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
153153
"\n"
154154
]
155155
}
@@ -177,14 +177,14 @@
177177
"name": "stdout",
178178
"output_type": "stream",
179179
"text": [
180-
"usage: plash_stop [-h] [--path PATH] [--app_id APP_ID]\n",
181-
"\n",
182-
"Access the '/stop' endpoint for your app\n",
183-
"\n",
184-
"options:\n",
185-
" -h, --help show this help message and exit\n",
186-
" --path PATH Path to project (default: .)\n",
187-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
180+
"usage: plash_stop [-h] [--path PATH] [--app_id APP_ID]\r\n",
181+
"\r\n",
182+
"Access the '/stop' endpoint for your app\r\n",
183+
"\r\n",
184+
"options:\r\n",
185+
" -h, --help show this help message and exit\r\n",
186+
" --path PATH Path to project (default: .)\r\n",
187+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
188188
"\n"
189189
]
190190
}
@@ -212,17 +212,17 @@
212212
"name": "stdout",
213213
"output_type": "stream",
214214
"text": [
215-
"usage: plash_logs [-h] [--path PATH] [--app_id APP_ID] [--mode {build,app}]\n",
216-
" [--tail]\n",
217-
"\n",
218-
"Prints the logs for your deployed app\n",
219-
"\n",
220-
"options:\n",
221-
" -h, --help show this help message and exit\n",
222-
" --path PATH Path to project (default: .)\n",
223-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
224-
" --mode {build,app} Choose between build or app logs (default: build)\n",
225-
" --tail Tail the logs (default: False)\n",
215+
"usage: plash_logs [-h] [--path PATH] [--app_id APP_ID] [--mode {build,app}]\r\n",
216+
" [--tail]\r\n",
217+
"\r\n",
218+
"Prints the logs for your deployed app\r\n",
219+
"\r\n",
220+
"options:\r\n",
221+
" -h, --help show this help message and exit\r\n",
222+
" --path PATH Path to project (default: .)\r\n",
223+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
224+
" --mode {build,app} Choose between build or app logs (default: build)\r\n",
225+
" --tail Tail the logs (default: False)\r\n",
226226
"\n"
227227
]
228228
}
@@ -250,16 +250,16 @@
250250
"name": "stdout",
251251
"output_type": "stream",
252252
"text": [
253-
"usage: plash_download [-h] [--path PATH] [--app_id APP_ID]\n",
254-
" [--save_path SAVE_PATH]\n",
255-
"\n",
256-
"Download your deployed app\n",
257-
"\n",
258-
"options:\n",
259-
" -h, --help show this help message and exit\n",
260-
" --path PATH Path to project (default: .)\n",
261-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
262-
" --save_path SAVE_PATH Save path (optional) (default: download)\n",
253+
"usage: plash_download [-h] [--path PATH] [--app_id APP_ID]\r\n",
254+
" [--save_path SAVE_PATH]\r\n",
255+
"\r\n",
256+
"Download your deployed app\r\n",
257+
"\r\n",
258+
"options:\r\n",
259+
" -h, --help show this help message and exit\r\n",
260+
" --path PATH Path to project (default: .)\r\n",
261+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
262+
" --save_path SAVE_PATH Save path (optional) (default: download)\r\n",
263263
"\n"
264264
]
265265
}
@@ -287,15 +287,15 @@
287287
"name": "stdout",
288288
"output_type": "stream",
289289
"text": [
290-
"usage: plash_delete [-h] [--path PATH] [--app_id APP_ID] [--force]\n",
291-
"\n",
292-
"Delete your deployed app\n",
293-
"\n",
294-
"options:\n",
295-
" -h, --help show this help message and exit\n",
296-
" --path PATH Path to project (default: .)\n",
297-
" --app_id APP_ID Overrides the .plash file in project root if provided\n",
298-
" --force Skip confirmation prompt (default: False)\n",
290+
"usage: plash_delete [-h] [--path PATH] [--app_id APP_ID] [--force]\r\n",
291+
"\r\n",
292+
"Delete your deployed app\r\n",
293+
"\r\n",
294+
"options:\r\n",
295+
" -h, --help show this help message and exit\r\n",
296+
" --path PATH Path to project (default: .)\r\n",
297+
" --app_id APP_ID Overrides the .plash file in project root if provided\r\n",
298+
" --force Skip confirmation prompt (default: False)\r\n",
299299
"\n"
300300
]
301301
}

plash_cli/core.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ def create_tar_archive(path:Path) -> tuple[io.BytesIO, int]:
125125
def deploy(
126126
path:Path=Path('.'), # Path to project
127127
app_id:str=None): # Overrides the .plash file in project root if provided
128-
'Ship your app to production'
128+
"Deploy app to production (ignores paths starting with '.')"
129129
print('Initializing deployment...')
130130
if app_id == '': print('Error: App ID cannot be an empty string'); return
131131
if not path.is_dir(): print("Error: Path should point to the project directory"); return

0 commit comments

Comments
 (0)