This repository was archived by the owner on Sep 3, 2025. It is now read-only.
Commit bf61164
committed
init: exit with error if route already exists
If 'init' tries to initialize a new route, but that route already exists on
disk (enabled or not), exit with an error. Without this explicit check, the
initialization will fail anyway (specifically, the bare repo clone), but the
call to 'RepositoryProvider.CreateRepository()' will enable the existing
route even if it was disabled. To avoid that unintended behavior and provide
clearer information to users, explicitly check for existing routes before
'CreateRepository()' and exit if the route already exists.
Signed-off-by: Victoria Dye <[email protected]>1 parent 05fe98e commit bf61164
1 file changed
+12
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
56 | 68 | | |
57 | 69 | | |
58 | 70 | | |
| |||
0 commit comments