| Age | Commit message (Collapse) | Author |
|
A real album (irregular.ninja/so.war.das) surfaced the bug: a Fujifilm
X100V whose battery died reset its clock to 2000-01-01, and every EXIF
timestamp on that roll was stamped with the bogus date instead of being
omitted. Trusting it at face value sorted that whole roll to the front
of the album, ahead of hundreds of correctly-dated 2020s photos.
EXIF years before 2001 are now treated the same as a missing date tag.
The no-date fallback also switches from source mtime to filename order,
since mtime is not reliable either -- bulk-copying/rsyncing an incoming
directory commonly rewrites every file's mtime to the transfer time,
unrelated to capture order -- while sequential camera filenames track
real shooting order even across a clock reset.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
Adds a new yes/no config setting (default no, preserving current behavior)
that orders the main album's photos by EXIF date taken (ascending) instead
of the default filename/shuffle order. Reuses the existing EXIF cache and
tag fallback chain (DateTimeOriginal -> DateTimeDigitized -> DateTime)
already used for tooltips/details/stats, so ordering never disagrees with
what those features show. Photos with no usable EXIF date fall back to
their source file's mtime, staying fully deterministic and crash-free.
CHRONOLOGICAL_ORDER takes precedence over SHUFFLE when both are enabled,
documented in album-photo-select.source.sh and docs/configuration.md.
Wired through the config registry (CONFIG_SPECS), validation, CLI flags
(--chronological/--no-chronological), --print-config, --dry-run,
--verbose logging, and shuriken.json generation metadata. Adds unit and
end-to-end tests covering default-off behavior, EXIF-date ordering with
shuffle precedence, and mtime fallback for EXIF-less photos.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
shuriken relied on GNU-only extensions (find -printf, stat -c, cp -a,
sort -R) and hard-refused to run outside Linux. Resolve each of the four
tools once at startup to a FIND/STAT/CP/SORT variable, preferring a
g-prefixed sibling (gfind, gstat, gcp, gsort) when present on PATH -
mirroring the $SED/$GREP/$DATE tool-selection pattern in the sibling
gemtexter project - so the same source runs unmodified on Linux, macOS,
and FreeBSD once GNU coreutils/findutils are installed there.
- src/lib/compat.source.sh: add resolve_gnu_tool + FIND/STAT/CP/SORT;
add a fast verify_gnu_tool_versions preflight (--version contains
"GNU") ahead of the existing behavioral probes, which now run against
the resolved variables instead of hardcoded tool names; split the
probes and error reporting into their own ~30-line functions.
- Replace the GNU-only find -printf / stat -c / cp -a / sort -R call
sites in photo-list, image, album-photo-select, metadata-cache,
config.staging, and random source files with the resolved variables.
POSIX-portable find/sort calls elsewhere are untouched.
- README.md: drop the "Linux-only" claim; document brew/pkg GNU
coreutils+findutils install steps for macOS and FreeBSD.
- tests/cli.sh: add coverage for the g-prefixed-sibling preference and
for the new --version-string preflight's error message, alongside the
existing behavioral-probe guard tests.
just build / just check-generated / just shellcheck / just test /
git diff --check all pass.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
Album owners can now set DETAILS_PAGE=no (or pass --no-details) to skip
generating each photo's *-details.html EXIF summary page and its "Details"
navigation redirects, without touching the normal thumbnail overview,
per-photo view pages, EXIF tooltips, or STATS_PAGE, which all stay
independently controlled. Every "Details" link (on view pages and stats
filter mini-album view pages) and every "-details" redirect stub is gated
on the setting so no generated page ever links to a file that was not
rendered. Wired the new field through CONFIG_SPECS (registry-driven
defaults/validation/print-config/CLI override), the --details/--no-details
CLI flags, usage() help, the verbose effective-config log, shuriken.json
generation metadata, and the dry-run plan. DETAILS_PAGE=yes (the default)
keeps prior output byte-for-byte identical.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
shuriken shells out to GNU-only features of the standard Unix tools
(find -printf, stat -c, cp -a, sort -R). Add require_gnu_tools in a new
src/lib/compat.source.sh, sourced early and invoked from main() before any
action runs. On invocation it feature-probes each tool in a throwaway temp
dir; if any probe fails it prints a clear error naming the offending tool
and exits 1, so non-GNU (macOS/BSD) environments fail fast instead of
producing broken output.
README gains a Platform compatibility section and the requirements line now
mentions GNU coreutils/findutils. Tests cover the find and stat rejection
paths; the shared test helper that builds a coreutils-without-imagemagick
PATH now includes cp and stat (which the guard probes).
|
|
Link the live irregular.ninja photo album and its codeberg source repo
as a ready-to-read example configuration exercising shuriken's features.
|
|
- Friendlier, less jargon-heavy quick-start comments in README.
- Simplify the --config row in the README main-flags table.
- Replace <...> HTML entities with backtick code spans in
generation.md and templates.md.
- Rephrase the supported-images note in configuration.md to drop the
find-specific 'maxdepth 1' phrasing in favour of plain English.
|
|
Trim README.md to a quick-start guide (install, init, generate, sync,
clean) with a main-flags table and feature-toggle summary, and move the
detailed reference material into focused pages under docs/:
installation, usage, configuration, generation, publishing, templates.
Correctness fixes carried over during the split:
- The 'Site generated ... with <URL>' source link lives in the page
header bar (header.tmpl), not the footer (footer.tmpl only renders
the tarball download). Fixed in docs and the SOURCE_URL code comment.
- --sync is a config-backed action and accepts --config PATH / reads
./shuriken.conf; the --config action list now includes it.
- --refresh-splash also re-copies the site favicon; documented.
- State the Bash 5.1 requirement (enforced by the script) in the docs.
- docs/stats-exif-audit.md: the EXIF cache moved to
metadata-cache.source.sh and the native-field parser extension was
implemented; add a status note and fix the stale module path.
bin/shuriken regenerated from the config.source.sh comment change.
|
|
The EXIF stats site (stats/ overview plus per-camera and filter mini-albums) was
generated by default. Flip the STATS_PAGE default to "no" so a plain album stays
lean; enable it explicitly with STATS_PAGE=yes or --stats. Updated the bundled
default config, the README ("off by default"), and the tests that relied on the
old default (the stats-rendering and dry-run-override tests now pass --stats /
set STATS_PAGE=yes; the print-config expectations now show STATS_PAGE=no).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
The footer "Site generated ... with <link>" was hardcoded to the shuriken.sh
repository. Make it configurable via the SOURCE_URL config variable and the
--source-url CLI flag (defaulting to the shuriken.sh repo, so existing sites are
unchanged). The footer derives the displayed text from the URL by stripping its
scheme. Plumbed through apply_config_defaults, CLI override targets/spec,
--print-config, the verbose effective-config log, and the header template's
new render_source_url_html (config_html) render var. Documented in
shuriken.default.conf and README; added a generation test asserting a custom
SOURCE_URL replaces the default footer link, and updated the print-config and
header render-var-subset expectations.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
The --clean action deleted DIST_DIR but left behind the staging/backup
directories the generation pipeline creates as siblings of DIST_DIR
(.shuriken.<basename>.staging.* / .backup.*). Users expect --clean to
remove all generation output, so extend it to also delete those.
Cleanup runs after the validate_clean_dist_dir safety guard (8n0), so a
dangerous DIST_DIR still aborts before any deletion. It only matches
shuriken's own basename-specific staging/backup prefixes (the exact
mktemp templates from config.staging.source.sh), uses nullglob so a
missing match never expands to a literal pattern, and only removes
directories. Unrelated dotfiles in the parent are never touched.
Update test_clean to assert the staging/backup dirs are removed while
unrelated entries survive, and document the behavior in the CLI usage
text and README.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
A scalar SYNC_DESTINATIONS containing spaces was word-split by the shared
resolve_config_array helper, breaking a single destination into multiple
broken arguments passed to rsync.
A list of rsync destinations is inherently a list, and array syntax is the
only spelling that preserves embedded spaces. resolve_sync_destinations now
detects a scalar declaration via declare -p and fails with a clear
config_error telling the user to use array syntax. The array path is
unchanged, and resolve_config_array's scalar word-splitting is left intact
for TAR_OPTS (where turning "-c -v" into separate options is desired).
Adds focused tests proving the scalar case errors without invoking rsync and
the array case preserves a space-containing destination as one argument.
Updates src/shuriken.default.conf and README.md to document the requirement.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
The generated pages link a favicon.ico that was always the bundled shuriken
favicon (copy_site_favicon hard-copied share/shuriken/assets/favicon.ico). Add a
FAVICON config variable and a --favicon PATH CLI flag: when set, that file is
published as favicon.ico instead of the bundled default; when empty, the bundled
favicon is used as before.
Plumbed through apply_config_defaults, CLI_OPTION_SPEC + override allowlist,
usage, print_config, the action config list and effective-setting log, and
validated (a non-empty FAVICON must be a readable file) before generation.
shuriken.default.conf and the README document it; a test covers a custom favicon,
its appearance in --print-config, and rejection of a missing file.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
The filter mini-albums put thousands of HTML files directly in the album root.
Reorganise so only the main album lives in DIST_DIR and all stats content goes
under stats/:
stats/index.html - the stats overview (was stats.html)
stats/<pagebase>/index.html - each filter gallery (was <pagebase>.html)
stats/<pagebase>/<index>.html - each filter view page (was <pagebase>--N.html)
Each mini-album is its own directory, so no single directory holds more than one
filter's pages. Links updated accordingly: the overview links to <pagebase>/, the
gallery thumbnails link to sibling <index>.html, view prev/next/gallery are
same-dir, and assets/album-details/back-to-stats resolve via the ../.. backhref.
The header Stats link and camera.tmpl back link point at stats/index.html.
Mini-albums still reuse the shared photos/thumbs/blurs assets and render in
parallel. Tests and the dry-run plan updated for the new layout; README documents
the stats/ subdirectory structure.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
Explain in the README that the per-photo EXIF identify cache now lives in a
volatile cache/ directory parallel to dist/: it is never deployed (--sync only
publishes DIST_DIR), persists across runs (and across a removed/rebuilt dist) to
skip the slow identify on unchanged photos, is left in place by --clean, and is
cleared once by --force.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
Final integration of the stats-site feature:
- Add STATS_PAGE config (default yes) mirroring SPLASH_PAGE through every
layer: shuriken.default.conf, apply_config_defaults, CLI_OPTION_SPEC
(--stats/--no-stats), the CLI_CONFIG_OVERRIDE_TARGETS allowlist (without
which the flag was silently ignored), usage text, yes/no validation,
print_config, the action config list + effective-setting log, the
generation metadata, and the dry-run plan.
- generate() now calls a gated generate_stats_pages helper after the album
pages (and before archiving, so the stats/camera pages are tarballed):
collect_photo_exif_stats + render_stats_page . . + render_camera_pages . .
- Emit "stats_page" in shuriken.json next to "splash_page".
- Gate the header Stats nav link behind STATS_PAGE via a new
render_stats_page_html config_html field, so it is hidden (no 404) when
stats are disabled.
- Document STATS_PAGE and --stats/--no-stats in the README.
- Tests: full --generate produces stats.html + camera-<slug>.html + the nav
link and stats_page=true; --no-stats suppresses all three and sets
stats_page=false; print-config and metadata expectations updated.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
The logo was embedded as a plain Markdown image, so renderers displayed
the 256x256 SVG at full/container size, dominating the top of the page.
Use an HTML <img> with width="160" (GitHub honors it) so the logo is a
modest header graphic instead of taking up the whole screen.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|