feat(core): Initial project scaffold and implementation: Deno CLI, ISO tooling, cloud-init generation, packaging and installer scripts

This commit is contained in:
2025-10-24 08:10:02 +00:00
commit ce06b5855a
31 changed files with 2873 additions and 0 deletions

58
uninstall.sh Executable file
View File

@@ -0,0 +1,58 @@
#!/usr/bin/env bash
set -e
# Colors
RED='\033[0;31m'
GREEN='\033[0;32m'
YELLOW='\033[1;33m'
BLUE='\033[0;34m'
NC='\033[0m' # No Color
INSTALL_DIR="/opt/isocreator"
BIN_LINK="/usr/local/bin/isocreator"
CACHE_DIR="$HOME/.isocreator"
echo -e "${BLUE}🗑️ isocreator uninstaller${NC}"
echo ""
# Remove binary
if [ -f "${INSTALL_DIR}/isocreator" ]; then
echo -e "${BLUE}📦 Removing binary from ${INSTALL_DIR}...${NC}"
rm -f "${INSTALL_DIR}/isocreator"
# Remove directory if empty
if [ -d "$INSTALL_DIR" ] && [ -z "$(ls -A $INSTALL_DIR)" ]; then
rmdir "$INSTALL_DIR"
fi
echo -e "${GREEN}✅ Binary removed${NC}"
else
echo -e "${YELLOW}⚠️ Binary not found at ${INSTALL_DIR}${NC}"
fi
# Remove symlink
if [ -L "$BIN_LINK" ]; then
echo -e "${BLUE}🔗 Removing symlink ${BIN_LINK}...${NC}"
rm -f "$BIN_LINK"
echo -e "${GREEN}✅ Symlink removed${NC}"
else
echo -e "${YELLOW}⚠️ Symlink not found at ${BIN_LINK}${NC}"
fi
# Ask about cache
if [ -d "$CACHE_DIR" ]; then
echo ""
echo -e "${YELLOW}Cache directory found: ${CACHE_DIR}${NC}"
read -p "Do you want to remove cached ISOs? (y/N) " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]; then
echo -e "${BLUE}🗑️ Removing cache directory...${NC}"
rm -rf "$CACHE_DIR"
echo -e "${GREEN}✅ Cache removed${NC}"
else
echo -e "${BLUE} Cache directory kept${NC}"
fi
fi
echo ""
echo -e "${GREEN}✅ isocreator uninstalled successfully!${NC}"