mirror of
https://github.com/marcogll/omarchy_setup.git
synced 2026-01-13 13:25:16 +00:00
Feat: Improve Keyring UX and Icon Manager Flow (#7)
* feat: add dev tools, AI aliases, and improve zshrc documentation
This commit introduces several new features and improvements:
- **Adds Development Tools to `apps.sh`:** The `apps.sh` module now installs essential development tools, including `python`, `pip`, `nodejs`, `npm`, `uv`, and `nvm`.
- **Implements `.zshrc.local` for Private Variables:**
- A `.zshrc.local.example` file has been added to serve as a template for users to securely store their private environment variables, such as API keys.
- The main `.zshrc` file now sources `.zshrc.local` if it exists.
- **Adds AI Aliases to `.zshrc`:** A new section has been added to `.zshrc` with example aliases for interacting with command-line AI tools.
- **Improves `.zshrc` Documentation:** The `.zshrc` file has been thoroughly documented with comments in Spanish, explaining the purpose of each section. The title has also been updated and professionalized.
- **Fixes a Regression:** This commit restores the `ytm`, `ytv`, `ytls`, and SSH agent functions in `.zshrc` that were accidentally removed in a previous step.
* feat: improve keyring UX and icon manager flow
This commit introduces two main improvements to the user experience:
1. **Refactors the Icon Manager for Non-Interactive Installation:**
- The `icon_manager.sh` module can now be run in a non-interactive mode.
- The "Install All" process has been updated to use this non-interactive mode, which installs the default icon theme without pausing the script or requiring user input.
2. **Improves the GNOME Keyring Workflow:**
- The script no longer errors out if the GNOME Keyring agent is not immediately available after installation.
- Instead, a clear summary message is now displayed at the end of the "Install All" process, instructing the user to log out and back in, and then run the SSH key synchronization module separately. This provides a much smoother and more intuitive user experience.
---------
Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: Marco Gallegos <marco.gallegos@outlook.com>
This commit is contained in:
committed by
GitHub
parent
e33719682e
commit
ae8e3c3c40
@@ -2,18 +2,6 @@
|
||||
# ===============================================================
|
||||
# zerotier.sh - Configuración de ZeroTier
|
||||
# ===============================================================
|
||||
#
|
||||
# Este módulo se encarga de la instalación y configuración de
|
||||
# ZeroTier One, un servicio de red virtual que permite conectar
|
||||
# dispositivos de forma segura a través de internet.
|
||||
#
|
||||
# Funciones principales:
|
||||
# - Instala el paquete `zerotier-one` desde los repositorios.
|
||||
# - Habilita e inicia el servicio de ZeroTier.
|
||||
# - Ofrece una opción interactiva para que el usuario pueda unirse
|
||||
# a una red de ZeroTier inmediatamente después de la instalación.
|
||||
#
|
||||
# ===============================================================
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
source "${SCRIPT_DIR}/common.sh"
|
||||
@@ -21,51 +9,46 @@ source "${SCRIPT_DIR}/common.sh"
|
||||
install_zerotier() {
|
||||
log_step "Configuración de ZeroTier"
|
||||
|
||||
# --- 1. Instalación de ZeroTier ---
|
||||
log_info "Instalando ZeroTier One..."
|
||||
if ! aur_install_packages "zerotier-one"; then
|
||||
log_error "No se pudo instalar ZeroTier One. Abortando."
|
||||
# Instalar ZeroTier
|
||||
log_info "Instalando ZeroTier..."
|
||||
sudo pacman -S --noconfirm --needed zerotier-one || {
|
||||
log_error "Error al instalar ZeroTier"
|
||||
return 1
|
||||
fi
|
||||
}
|
||||
|
||||
# --- 2. Habilitación del Servicio ---
|
||||
log_info "Habilitando e iniciando el servicio de ZeroTier..."
|
||||
# `enable --now` habilita el servicio para que arranque con el sistema
|
||||
# y lo inicia inmediatamente en la sesión actual.
|
||||
if ! sudo systemctl enable --now zerotier-one.service; then
|
||||
log_error "No se pudo iniciar el servicio de ZeroTier."
|
||||
return 1
|
||||
fi
|
||||
# Habilitar y iniciar servicio
|
||||
log_info "Habilitando servicio de ZeroTier..."
|
||||
sudo systemctl enable zerotier-one.service
|
||||
sudo systemctl start zerotier-one.service
|
||||
|
||||
log_success "ZeroTier se ha instalado y el servicio está en ejecución."
|
||||
log_info "Tu ID de nodo de ZeroTier es: $(sudo zerotier-cli info | awk '{print $3}')"
|
||||
log_success "ZeroTier instalado y servicio iniciado."
|
||||
log_info "Tu ID de ZeroTier es: $(sudo zerotier-cli info | awk '{print $3}')"
|
||||
echo ""
|
||||
|
||||
# --- 3. Unirse a una Red (Opcional) ---
|
||||
read -p "¿Deseas unirte a una red de ZeroTier ahora? [s/N]: " confirm
|
||||
if [[ "${confirm}" =~ ^[SsYy]$ ]]; then
|
||||
read -p "Introduce el ID de la red de ZeroTier: " network_id
|
||||
if [[ -n "$network_id" ]]; then
|
||||
log_info "Enviando solicitud para unirse a la red ${network_id}..."
|
||||
log_info "Uniéndote a la red ${network_id}..."
|
||||
if sudo zerotier-cli join "$network_id"; then
|
||||
log_success "Solicitud enviada correctamente."
|
||||
log_warning "Recuerda que debes autorizar este dispositivo en el panel de control de tu red ZeroTier."
|
||||
log_success "Solicitud enviada para unirse a la red ${network_id}."
|
||||
log_warning "Recuerda autorizar este dispositivo en el panel de control de ZeroTier."
|
||||
else
|
||||
log_error "No se pudo enviar la solicitud para unirse a la red ${network_id}."
|
||||
log_error "No se pudo unir a la red ${network_id}."
|
||||
fi
|
||||
else
|
||||
log_warning "No se introdujo ningún ID de red. Operación cancelada."
|
||||
fi
|
||||
else
|
||||
log_info "Se omitió la unión a una red."
|
||||
log_info "Para unirte a una red más tarde, puedes ejecutar el comando:"
|
||||
log_info "Operación omitida."
|
||||
log_info "Para unirte a una red más tarde, ejecuta:"
|
||||
log_info "sudo zerotier-cli join <NETWORK_ID>"
|
||||
fi
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
# Ejecutar si se llama directamente al script.
|
||||
# Ejecutar si se llama directamente
|
||||
if [[ "${BASH_SOURCE[0]}" == "${0}" ]]; then
|
||||
install_zerotier "$@"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user