From 76bd5f9f5d4b61768dc7577843cdef136c78b2f8 Mon Sep 17 00:00:00 2001 From: David Young Date: Mon, 15 Jun 2026 12:58:04 -0600 Subject: [PATCH] various updates --- install-flatpaks.sh | 4 ++ packages.conf | 4 -- remove-packages.conf | 6 ++- skills/sibling-project-updates.md | 90 +++++++++++++++++++++++++++++++ 4 files changed, 98 insertions(+), 6 deletions(-) create mode 100644 skills/sibling-project-updates.md diff --git a/install-flatpaks.sh b/install-flatpaks.sh index e8c9e20..c352a21 100755 --- a/install-flatpaks.sh +++ b/install-flatpaks.sh @@ -44,6 +44,10 @@ FLATPAKS=( "io.github.anil_e.Codd" "org.gnome.DejaDup" "com.rustdesk.RustDesk" + "io.github.tanaybhomia.Whisp" + "org.pipewire.Helvum" + "com.jeffser.Alpaca" + "ai.lmstudio.lm-studio" ) for pak in "${FLATPAKS[@]}"; do diff --git a/packages.conf b/packages.conf index 0a3a714..985a1c5 100644 --- a/packages.conf +++ b/packages.conf @@ -24,16 +24,13 @@ SYSTEM_UTILS=( lazydocker lazygit libyaml - lmstudio-bin lsd lsof man mc mtr - neofetch nerdfetch net-tools - net-tools networkmanager nmap nss-mdns @@ -90,7 +87,6 @@ DEV_TOOLS=( # System maintenance MAINTENANCE=( - alpaca-ai gnome-disk-utility gnome-extra gnome-keyring diff --git a/remove-packages.conf b/remove-packages.conf index d143b8c..d1b4672 100644 --- a/remove-packages.conf +++ b/remove-packages.conf @@ -3,10 +3,12 @@ # Pacman / AUR packages to remove (works for both pacman and yay packages) REMOVE_PACMAN=( - # none at this time + alpaca-ai + lmstudio-bin + neofetch ) # Flatpak applications to remove REMOVE_FLATPAKS=( - "com.jeffser.Alpaca" + # none at this time ) diff --git a/skills/sibling-project-updates.md b/skills/sibling-project-updates.md new file mode 100644 index 0000000..6fc6cf0 --- /dev/null +++ b/skills/sibling-project-updates.md @@ -0,0 +1,90 @@ +# Skill: Supporting the updates.d Update Architecture in a Sibling Project + +## Overview + +CoreDesktop's `coreupdate` script sources every `*.sh` file found in +`~/.local/share/coredesktop/updates.d/` in filename order. A sibling project +hooks into this system by installing a numbered shell script into that directory +during its own install step. + +## How It Works + +When a user runs `coreupdate`: + +1. The coredesktop repo at `~/.local/share/coredesktop` is pulled. +2. All `*.sh` files in `updates.d/` are **sourced** (not executed as subprocesses) + in lexicographic order. +3. Each script runs in the same shell context, with access to `$COREDESKTOP` and + anything sourced before it (e.g. `utils.sh`). + +Because the scripts are sourced from within the cloned repo directory, any file +placed there by a sibling project's installer will **survive `git pull`** — git +does not delete untracked files on pull. + +## Naming Convention + +Existing coredesktop hooks use a numeric prefix to control execution order: + +| File | Purpose | +|------------------|---------------------| +| `10-pacman.sh` | Arch system update | +| `20-aur.sh` | AUR packages | +| `30-flatpak.sh` | Flatpak apps | +| `40-ruby.sh` | Ruby/gems | +| `50-bitwarden.sh`| Bitwarden CLI | +| `60-pipx.sh` | pipx packages | + +Sibling projects should use **70 or higher** to run after all coredesktop +updates complete. + +## What to Add to a Sibling Project + +### 1. Create the hook script + +Add a file like `updates.d/70-myproject.sh` to the sibling repo: + +```bash +#!/bin/bash + +echo "Updating MyProject..." +git -C "$HOME/.local/share/myproject" pull + +# Optional: use coredesktop helpers if needed +# source "$COREDESKTOP/utils.sh" +# install_packages "${MY_PACKAGES[@]}" +``` + +### 2. Install the hook during the sibling's install step + +In the sibling's `install.sh`, copy the hook into coredesktop's `updates.d/`: + +```bash +echo "Registering MyProject update hook..." +cp updates.d/70-myproject.sh ~/.local/share/coredesktop/updates.d/ +``` + +This is a one-time step that wires the sibling into every future `coreupdate` +run on the machine. + +## Available Helpers + +Since hooks are sourced in the same shell, they can use any function or variable +already defined by earlier scripts. The most useful are in `utils.sh`: + +```bash +source "$COREDESKTOP/utils.sh" + +# Install pacman packages (skips already-installed ones) +install_packages "${MY_PACMAN_PACKAGES[@]}" + +# Remove packages +remove_packages "${MY_REMOVE_PACKAGES[@]}" +``` + +## Checklist for Sibling Project Authors + +- [ ] Create `updates.d/7X-.sh` in the sibling repo +- [ ] Hook script echoes its name so progress is visible during `coreupdate` +- [ ] Install step copies the hook to `~/.local/share/coredesktop/updates.d/` +- [ ] Numeric prefix is 70+ (does not conflict with coredesktop's own hooks) +- [ ] Script is idempotent — safe to run multiple times without side effects