Clarify CLI reinstall steps

This commit is contained in:
thePR0M3TH3AN
2025-07-10 22:47:23 -04:00
parent 26030611b1
commit 2609064016
3 changed files with 32 additions and 0 deletions

View File

@@ -273,6 +273,12 @@ endlocal
"@
Set-Content -Path $LauncherPath -Value $LauncherContent -Force
$existingSeedpass = Get-Command seedpass -ErrorAction SilentlyContinue
if ($existingSeedpass -and $existingSeedpass.Source -ne $LauncherPath) {
Write-Warning "Another 'seedpass' command was found at $($existingSeedpass.Source)."
Write-Warning "Ensure '$LauncherDir' comes first in your PATH or remove the old installation."
}
# 6. Add launcher directory to User's PATH if needed
Write-Info "Checking if '$LauncherDir' is in your PATH..."
$UserPath = [System.Environment]::GetEnvironmentVariable("Path", "User")
@@ -287,3 +293,4 @@ if (($UserPath -split ';') -notcontains $LauncherDir) {
Write-Success "Installation/update complete!"
Write-Info "To run the application, please open a NEW terminal window and type: seedpass"
Write-Info "'seedpass' resolves to: $(Get-Command seedpass | Select-Object -ExpandProperty Source)"

View File

@@ -132,9 +132,16 @@ exec "$VENV_DIR/bin/python" -m seedpass.cli "\$@"
EOF2
chmod +x "$LAUNCHER_PATH"
existing_cmd=$(command -v seedpass 2>/dev/null || true)
if [ -n "$existing_cmd" ] && [ "$existing_cmd" != "$LAUNCHER_PATH" ]; then
print_warning "Another 'seedpass' command was found at $existing_cmd."
print_warning "Ensure '$LAUNCHER_DIR' comes first in your PATH or remove the old installation."
fi
# 8. Final instructions
print_success "Installation/update complete!"
print_info "You can now run the application by typing: seedpass"
print_info "'seedpass' resolves to: $(command -v seedpass)"
if [[ ":$PATH:" != *":$LAUNCHER_DIR:"* ]]; then
print_warning "Directory '$LAUNCHER_DIR' is not in your PATH."
print_warning "Please add 'export PATH=\"$HOME/.local/bin:$PATH\"' to your shell's config file (e.g., ~/.bashrc, ~/.zshrc) and restart your terminal."