Skip to content

Latest commit

 

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

About

A Bash script that compares every package in a Slackware repository (or just the packages installed on your machine) against the latest upstream release known to Repology, and can optionally fetch the newest source and rebuild outdated packages from their SlackBuilds.

How it works

  1. Downloads the FILE_LIST of a Slackware repository (default: slackware64-current) — or reads a local listing, or your installed package database.
  2. Queries the Repology API for each package, translating Slackware package names to Repology project names where they differ. A run needing more than 200 live lookups pages through Repology's bulk endpoint instead, which covers the whole repository in a handful of requests; anything the bulk listing misses falls back to a per-package lookup.
  3. Reports each package as one of: uptodate, outdated, newer (ahead of the tracker), norelease (tracked, but upstream has no release), snapshot (a rolling/ignored version Repology won't compare), nottracked, or failed (the lookup itself did not succeed). The summary counts every one of them, so its figures always add up to the number of packages checked.
  4. With --build (experimental), fetches the newest upstream release for each outdated package (from git forges, PyPI, RubyGems, SourceForge, or plain HTTP/FTP directory listings) into your local Slackware source tree and runs the package's <pkg>.SlackBuild with VERSION set to the fetched version. Only a release matching the version Repology reported is accepted — if it can't be found, the fetch is reported as failed and the existing sources are built instead, so a "build succeeded" line always says which version was actually built.

Repology lookups are cached for 24 hours under ~/.cache/slackology (or $XDG_CACHE_HOME/slackology) to keep repeat runs fast and API-friendly. Requests are rate-limited and parallelized with a configurable number of workers.

Requirements

  • bash 5.0 or newer (uses $EPOCHSECONDS/$EPOCHREALTIME and namerefs), plus curl, jq, GNU xargs (for -d), flock, mktemp, sleep, wc, and nproc unless you pass -j.
  • For --build additionally: git, timeout, awk, grep, GNU sort (for -V), tail, head, find, cp.

The script checks for each of these at startup and stops with a clear message if one is missing, rather than producing a subtly wrong report.

Usage

# Check all of slackware64-current against upstream
./slackology.sh

# Check only what's installed on this machine
./slackology.sh --installed

# Check a single package (case and _/- differences don't matter)
./slackology.sh -p glibc

# Fetch latest sources and rebuild outdated packages from a local source tree
./slackology.sh --build --source-dir /path/to/source

Run ./slackology.sh --help for the full list of options (custom repo URL, parallelism, API rate limiting, cache control, etc.).

Files

File Purpose
slackology.sh The main script.
repologyNames.map Maps Slackware package names to Repology project names (e.g. gcc-g++gcc). Case and _/- differences are normalized automatically, so only genuine renames need entries. Auto-detected next to the script; override with -R.
upstreamLinks.tsv TSV of package<TAB>upstream_url, used by --build to locate each package's upstream source. Keys must match the Slackware package name exactly (this file, unlike repologyNames.map, is not normalized). Auto-detected next to the script; override with -U.

Notes

  • The Slackware repo listing itself is never cached — it's fetched fresh every run. Only per-package Repology lookups are cached (clear them with -c/--clear-cache, bypass with -n/--no-cache).
  • Please be considerate of the Repology API: the defaults (3 concurrent requests, 1.1 s spacing) are chosen to stay well within polite limits.
  • Exit status is non-zero if any package produced no result at all, if a --build build failed, or if an outdated package had no local SlackBuild to build.

About

No description, website, or topics provided.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages