drop fastfetch from machine-setup
It stopped a real install. The guard covered the wrong half: a PPA that fails to ADD is caught and skipped, but one that adds cleanly while carrying no package for the running codename gets past that and dies on `pkg_install_now fastfetch`. It was also the only tool in the set with no source but a third-party PPA on Ubuntu 24.04 and older. A neofetch clone is not worth a branch in a script whose whole job is to survive machines nobody has seen. Removed from tools_default, the tool_command mapping and its installer. No shell config invoked it, so nothing is left calling a missing binary. software-properties-common stays in the core apt list for now, with a note: it provides add-apt-repository, the fastfetch PPA was its only caller, and Docker writes its own sources.list.d entry by hand — so it is now dead weight. Left as a separate decision rather than folded into this one. Verified: bash -n on all four scripts, and no live reference remains. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -84,9 +84,16 @@ LAST_SKIPPED=()
|
|||||||
pkgs_core() {
|
pkgs_core() {
|
||||||
case "$PM" in
|
case "$PM" in
|
||||||
apt)
|
apt)
|
||||||
# apt-transport-https, lsb-release and software-properties-common are not
|
# apt-transport-https and lsb-release are not tools — they are what lets a
|
||||||
# tools — they are what lets later steps add the Docker repository and the
|
# later step add the Docker repository. They have no counterpart on the
|
||||||
# fastfetch PPA. They have no counterpart on the other systems.
|
# other systems.
|
||||||
|
#
|
||||||
|
# software-properties-common is still here and is no longer needed by
|
||||||
|
# anything: it provides `add-apt-repository`, and the fastfetch PPA was its
|
||||||
|
# only caller until that was removed on 2026-08-14 (Docker writes its own
|
||||||
|
# sources.list.d entry by hand). Left in deliberately rather than dropped
|
||||||
|
# in the same change — it is one small package, and pulling it is a
|
||||||
|
# separate decision from removing the tool that wanted it.
|
||||||
echo curl ca-certificates gnupg git jq unzip \
|
echo curl ca-certificates gnupg git jq unzip \
|
||||||
apt-transport-https lsb-release software-properties-common \
|
apt-transport-https lsb-release software-properties-common \
|
||||||
wget zip build-essential python3 btop htop tree tmux ripgrep fd-find net-tools \
|
wget zip build-essential python3 btop htop tree tmux ripgrep fd-find net-tools \
|
||||||
|
|||||||
@@ -20,10 +20,17 @@
|
|||||||
MACHINE_SETUP_TOOLS_LOADED=1
|
MACHINE_SETUP_TOOLS_LOADED=1
|
||||||
|
|
||||||
# The set installed on every machine, in the order they are fetched.
|
# The set installed on every machine, in the order they are fetched.
|
||||||
tools_default() { echo lazydocker lazygit starship fastfetch; }
|
#
|
||||||
|
# fastfetch was here until 2026-08-14 and was removed after it stopped a real
|
||||||
|
# install. It is the only one of these with no source but a third-party PPA on
|
||||||
|
# Ubuntu 24.04 and older, and the failure was in the half that was not guarded:
|
||||||
|
# a PPA that ADDS cleanly but carries no package for the running codename gets
|
||||||
|
# past the `|| skip` and dies on the install instead. A neofetch clone is not
|
||||||
|
# worth a branch in a script that has to survive on machines nobody has seen.
|
||||||
|
tools_default() { echo lazydocker lazygit starship; }
|
||||||
|
|
||||||
# The command that proves a tool is already here. Same as the tool name for all
|
# The command that proves a tool is already here. Same as the tool name for all
|
||||||
# four today, but kept as a mapping because that is not a rule — a package and
|
# three today, but kept as a mapping because that is not a rule — a package and
|
||||||
# the binary it provides disagree often enough (fd-find/fdfind) to be worth the
|
# the binary it provides disagree often enough (fd-find/fdfind) to be worth the
|
||||||
# indirection.
|
# indirection.
|
||||||
tool_command() {
|
tool_command() {
|
||||||
@@ -31,7 +38,6 @@ tool_command() {
|
|||||||
lazydocker) echo lazydocker ;;
|
lazydocker) echo lazydocker ;;
|
||||||
lazygit) echo lazygit ;;
|
lazygit) echo lazygit ;;
|
||||||
starship) echo starship ;;
|
starship) echo starship ;;
|
||||||
fastfetch) echo fastfetch ;;
|
|
||||||
*) echo "$1" ;;
|
*) echo "$1" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
@@ -80,23 +86,6 @@ tool_install_starship() {
|
|||||||
curl -fsSL https://starship.rs/install.sh | sh -s -- -y -b /usr/local/bin >/dev/null
|
curl -fsSL https://starship.rs/install.sh | sh -s -- -y -b /usr/local/bin >/dev/null
|
||||||
}
|
}
|
||||||
|
|
||||||
# A distribution package everywhere, but not always one the distribution ships:
|
|
||||||
# Ubuntu only picked fastfetch up in 24.10, so on noble and older the PPA is the
|
|
||||||
# only source. Checked rather than assumed, so the PPA stops being added the
|
|
||||||
# moment the archive has it.
|
|
||||||
tool_install_fastfetch() {
|
|
||||||
if [[ "$PM" == "apt" ]] && ! apt-cache policy fastfetch 2>/dev/null | grep -q 'Candidate: [0-9]'; then
|
|
||||||
info " fastfetch is not in this release's archive — adding the upstream PPA"
|
|
||||||
add-apt-repository -y ppa:zhangsongcui3371/fastfetch >/dev/null 2>&1 ||
|
|
||||||
{
|
|
||||||
warn "could not add the fastfetch PPA — skipping"
|
|
||||||
return 0
|
|
||||||
}
|
|
||||||
pkg_refresh >/dev/null 2>&1
|
|
||||||
fi
|
|
||||||
pkg_install_now fastfetch
|
|
||||||
}
|
|
||||||
|
|
||||||
# -----------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
# Acting
|
# Acting
|
||||||
# -----------------------------------------------------------------------------
|
# -----------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -183,9 +183,9 @@ fi
|
|||||||
save_answers
|
save_answers
|
||||||
|
|
||||||
# Always, and outside any step: everything below reads this index — core utils,
|
# Always, and outside any step: everything below reads this index — core utils,
|
||||||
# the fastfetch PPA, the Docker repo — and `step` skips a step whose name is
|
# the Docker repo — and `step` skips a step whose name is already in the progress
|
||||||
# already in the progress file. With the refresh inside one of those, a resumed
|
# file. With the refresh inside one of those, a resumed run installed against
|
||||||
# run installed against whatever the index happened to say hours or days ago.
|
# whatever the index happened to say hours or days ago.
|
||||||
echo ""
|
echo ""
|
||||||
info "Refreshing the package index..."
|
info "Refreshing the package index..."
|
||||||
pkg_refresh >/dev/null
|
pkg_refresh >/dev/null
|
||||||
|
|||||||
Reference in New Issue
Block a user