feat(apps): add dedicated installer for Calibre

Integrates the official Calibre e-book manager installer into the `apps.sh` module.

This change introduces a new function, `install_calibre`, which:
- Checks if Calibre is already installed to prevent re-installation.
- Uses the recommended `wget` command to download and execute the official Linux installer script.
- Provides clear logging for the installation process.

The function is called from the main execution flow, ensuring Calibre is installed alongside other essential applications.
This commit is contained in:
google-labs-jules[bot]
2025-11-21 04:19:17 +00:00
parent 3f0c0d4e09
commit d88445b34e

View File

@@ -143,6 +143,31 @@ install_nvm() {
fi fi
} }
# ---------------------------------------------------------------
# install_calibre()
# ---------------------------------------------------------------
# Instala Calibre, el gestor de libros electrónicos.
#
# Utiliza el instalador oficial de Calibre para sistemas Linux,
# que descarga y configura la última versión estable.
# ---------------------------------------------------------------
install_calibre() {
log_step "Instalación de Calibre"
if command_exists calibre; then
log_success "Calibre ya está instalado."
return 0
fi
log_info "Instalando Calibre..."
if sudo -v && wget -nv -O- https://download.calibre-ebook.com/linux-installer.sh | sudo sh /dev/stdin; then
log_success "Calibre instalado correctamente."
else
log_error "Falló la instalación de Calibre."
return 1
fi
}
# --------------------------------------------------------------- # ---------------------------------------------------------------
# run_module_main() # run_module_main()
# --------------------------------------------------------------- # ---------------------------------------------------------------
@@ -218,6 +243,9 @@ run_module_main() {
# Instalar Homebrew # Instalar Homebrew
install_homebrew install_homebrew
# Instalar Calibre
install_calibre
log_info "Instalando aplicaciones multimedia..." log_info "Instalando aplicaciones multimedia..."
sudo pacman -S --noconfirm --needed "${PACMAN_MULTIMEDIA[@]}" || { sudo pacman -S --noconfirm --needed "${PACMAN_MULTIMEDIA[@]}" || {
log_warning "Algunos paquetes multimedia no se pudieron instalar" log_warning "Algunos paquetes multimedia no se pudieron instalar"