explaingit

ddrboxman/hasherator

Analysis updated 2026-07-04 · repo last pushed 2018-09-27

GoAudience · developerComplexity · 2/5DormantSetup · easy

TLDR

A Go package that automatically renames your CSS and JavaScript files with a unique content hash so browsers always load the latest version instead of a stale cached copy.

Mindmap

mindmap
  root((repo))
    What it does
      Hashes asset filenames
      Copies files to work dir
      Builds filename lookup map
    Use cases
      Blogs and dashboards
      Frequent frontend tweaks
      Zero-downtime updates
    Tech stack
      Go
      File watcher integration
    Audience
      Go web developers
      SaaS builders
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Serve always-fresh CSS and JavaScript files from a Go web app without asking users to clear their browser cache.

USE CASE 2

Run a blog or SaaS dashboard where you frequently update stylesheets and need visitors to see changes immediately.

USE CASE 3

Update frontend assets at runtime without restarting your Go server by pairing with a file-watching library.

USE CASE 4

Keep clean original filenames in version control while serving hashed copies that bust browser caches automatically.

What is it built with?

Go

How does it compare?

ddrboxman/hasheratoraasheeshlikepanner/vaseananthmenon10/xfpl
Stars00
LanguageGoGoGo
Last pushed2018-09-27
MaintenanceDormant
Setup difficultyeasymoderatemoderate
Complexity2/54/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min

In plain English

Hasherator is a tool for Go web applications that solves a common annoyance: when you update a CSS or JavaScript file, browsers keep showing visitors the old version because they've cached it locally. Instead of asking users to hard-refresh their browser or manually bumping version numbers every time you change a stylesheet, this package automatically renames your asset files with a unique hash based on their contents. When a file changes, its hash changes, and the browser treats it as a brand-new file and fetches the fresh copy. At a high level, when your application starts up, you point the tool at a source directory containing your original files. It creates a separate working directory, copies each file over, and appends a hash string to the filename, so a file like bootstrap.min.css becomes something like bootstrap.min-ec3bb52a00e176a7181d454dffaea219.css. It also builds a lookup map that ties original filenames to their hashed versions, so your application's templates can reference the correct hashed name without you hardcoding it. This is meant for developers building Go web backends who serve static assets like stylesheets and scripts. If you run a blog, a SaaS dashboard, or any web app where you frequently tweak frontend files, this handles the cache-busting problem automatically. Your project repository keeps the clean, original filenames, while the hashed working directory is ignored by version control. A notable feature is the ability to update assets at runtime without restarting your server. By pairing it with a file-watching library, you can detect when someone modifies a stylesheet and automatically re-hash the files in the background, swapping in the new directory seamlessly. This means a content update or styling tweak can go live without any downtime.

Copy-paste prompts

Prompt 1
I have a Go web app serving static CSS and JS files. Show me how to integrate Hasherator to automatically hash filenames so browsers stop caching old versions.
Prompt 2
Help me set up Hasherator with a file-watching library so I can update stylesheets at runtime without restarting my Go server.
Prompt 3
I want to use Hasherator in my Go templates to reference hashed asset filenames. Show me how to use the lookup map it generates.
Prompt 4
Walk me through configuring Hasherator to point at my source assets directory and generate a separate working directory of hashed files.

Frequently asked questions

What is hasherator?

A Go package that automatically renames your CSS and JavaScript files with a unique content hash so browsers always load the latest version instead of a stale cached copy.

What language is hasherator written in?

Mainly Go. The stack also includes Go.

Is hasherator actively maintained?

Dormant — no commits in 2+ years (last push 2018-09-27).

How hard is hasherator to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is hasherator for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub ddrboxman on gitmyhub

Verify against the repo before relying on details.