Skip to content

Commit da3b2d7

Browse files
committed
deploy: Refuse to run from a user's home directory
- TBH there's lots of other ways to shoot yourself in the foot but this is an easy one - Fixes #137
1 parent aadc1d5 commit da3b2d7

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

robotpy_installer/cli_deploy.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,12 @@ def run(
166166
team: typing.Optional[int],
167167
no_resolve: bool,
168168
):
169+
if main_file.parent == pathlib.Path.home():
170+
print_err(
171+
"ERROR: running 'deploy' from your home directory is not supported!"
172+
)
173+
return False
174+
169175
# run the test suite before uploading
170176
if not skip_tests:
171177
test_args = [

0 commit comments

Comments
 (0)