feat: improve installation system with user-local and system-wide options
Update justfile installation system to provide better user experience: Installation Improvements: - `just install` - installs to ~/bin (user-local, no sudo required) - `just system-install` - installs to /usr/local/bin (system-wide, requires sudo) - `just uninstall` - removes from ~/bin - `just system-uninstall` - removes from /usr/local/bin (requires sudo) Benefits: - User-local installation by default (follows Unix best practices) - No sudo required for personal installations - Clear separation between user and system installs - Easy uninstallation for both scenarios - Helpful PATH reminder for ~/bin installation Documentation Updates: - Update CLAUDE.md with new installation commands - Update IMPLEMENTATION_COMPARISON.md deployment examples - Include uninstall instructions for both methods This follows modern software distribution practices where user-local installation is preferred for development tools, with system-wide installation available when needed for shared environments. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
2cd65fd137
commit
cf41a8c1c5
3 changed files with 44 additions and 10 deletions
29
justfile
29
justfile
|
|
@ -31,14 +31,39 @@ build-go-release:
|
|||
# Build optimized Rust release (already built with --release above)
|
||||
build-rust-release: build-rust
|
||||
|
||||
# Install binaries to /usr/local/bin (requires sudo)
|
||||
# Install binaries to ~/bin (user-local installation)
|
||||
install: build-release
|
||||
@echo "Installing binaries to ~/bin..."
|
||||
mkdir -p ~/bin
|
||||
cp go/mail2couch-go ~/bin/
|
||||
cp rust/target/release/mail2couch-rs ~/bin/
|
||||
chmod +x ~/bin/mail2couch-go
|
||||
chmod +x ~/bin/mail2couch-rs
|
||||
@echo "✅ Installed mail2couch-go and mail2couch-rs to ~/bin"
|
||||
@echo "💡 Make sure ~/bin is in your PATH"
|
||||
|
||||
# Install binaries to /usr/local/bin (system-wide installation, requires sudo)
|
||||
system-install: build-release
|
||||
@echo "Installing binaries to /usr/local/bin..."
|
||||
sudo cp go/mail2couch-go /usr/local/bin/
|
||||
sudo cp rust/target/release/mail2couch-rs /usr/local/bin/
|
||||
sudo chmod +x /usr/local/bin/mail2couch-go
|
||||
sudo chmod +x /usr/local/bin/mail2couch-rs
|
||||
@echo "✅ Installed mail2couch-go and mail2couch-rs"
|
||||
@echo "✅ Installed mail2couch-go and mail2couch-rs to /usr/local/bin"
|
||||
|
||||
# Uninstall binaries from ~/bin
|
||||
uninstall:
|
||||
@echo "Uninstalling binaries from ~/bin..."
|
||||
rm -f ~/bin/mail2couch-go
|
||||
rm -f ~/bin/mail2couch-rs
|
||||
@echo "✅ Uninstalled mail2couch-go and mail2couch-rs from ~/bin"
|
||||
|
||||
# Uninstall binaries from /usr/local/bin (requires sudo)
|
||||
system-uninstall:
|
||||
@echo "Uninstalling binaries from /usr/local/bin..."
|
||||
sudo rm -f /usr/local/bin/mail2couch-go
|
||||
sudo rm -f /usr/local/bin/mail2couch-rs
|
||||
@echo "✅ Uninstalled mail2couch-go and mail2couch-rs from /usr/local/bin"
|
||||
|
||||
# Run tests for both implementations
|
||||
test: test-go test-rust
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue