mirror of
https://github.com/tw93/Mole.git
synced 2026-03-22 22:30:08 +00:00
🎨 Loading optimization and better use of links
This commit is contained in:
11
mole
11
mole
@@ -148,11 +148,11 @@ update_mole() {
|
||||
fi
|
||||
|
||||
# Download and run installer with progress
|
||||
echo -e "${BLUE}◎${NC} Downloading latest version..."
|
||||
echo -e "${BLUE}|${NC} Downloading latest version..."
|
||||
|
||||
local installer_url="https://raw.githubusercontent.com/tw93/mole/main/install.sh"
|
||||
local tmp_installer
|
||||
tmp_installer="$(mktemp)" || { log_error "Update failed"; exit 1; }
|
||||
tmp_installer="$(mktemp_file)" || { log_error "Update failed"; exit 1; }
|
||||
|
||||
# Download installer with progress
|
||||
if command -v curl >/dev/null 2>&1; then
|
||||
@@ -181,7 +181,7 @@ update_mole() {
|
||||
local install_dir
|
||||
install_dir="$(cd "$(dirname "$mole_path")" && pwd)"
|
||||
|
||||
echo -e "${BLUE}◎${NC} Installing update..."
|
||||
echo -e "${BLUE}|${NC} Installing update..."
|
||||
|
||||
# Run installer with visible output (but capture for error handling)
|
||||
local install_output
|
||||
@@ -286,10 +286,7 @@ remove_mole() {
|
||||
echo ""
|
||||
|
||||
# Confirm removal
|
||||
read -p "Are you sure you want to remove Mole? (y/N): " -n 1 -r
|
||||
echo ""
|
||||
|
||||
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
|
||||
read -p "Are you sure you want to remove Mole? (y/N): " -n 1 -r; echo ""; if [[ ! $REPLY =~ ^[Yy]$ ]]; then
|
||||
echo "Cancelled."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user