Ross ROSS = Recommend OSS · open-source software intelligence for agents

spf13/afero

The Universal Filesystem Abstraction for Go observed · 2026-08-28

github.com/spf13/afero · Go · Apache-2.0 (permissive) observed · 2026-08-28

Health v2 · maintenance only

76/100

  • Activity 97
  • Release rhythm 35
  • Longevity 100
How is this computed?

round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-03. Adoption (stars, forks) is never an input.

  • gap_med: 64
  • age_days: 4327
  • days_rel: 359
  • days_push: 19
  • n_releases_24m: 4

Full methodology

Adoption not part of the score

6692 stars · 570 forks observed · 2026-08-28

What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-29, confidence not recorded

Afero is a filesystem abstraction library for Go that provides a universal interface over multiple storage backends, including local disk, in-memory, archives, and remote systems. It acts as a drop-in replacement for the standard os package, enabling easy testing and composable filesystem layers like caching, sandboxing, and path restriction.

Use cases

  • mock the filesystem in Go unit tests
  • swap file storage backends without changing application code
  • sandbox file access to a subdirectory
  • cache reads from a slow network filesystem
  • read and write files inside zip or tar archives
  • make Go code portable across local, cloud, and remote storage

When to choose

  • you need fast, isolated filesystem tests without touching disk
  • you want to abstract storage backends behind one interface
  • you need layered filesystem behaviors like copy-on-write or caching
  • you want os-package-compatible file APIs with io/fs support

When to avoid

  • you only ever touch the local disk and never test file logic
  • you need a POSIX-compliant full filesystem implementation
  • your code depends on os-specific features outside the abstraction

Facets

library · maturity stable

file-system testing mocking developer-tools files testing go cross-platform filesystem-abstraction vfs in-memory-filesystem drop-in-replacement os-package

1 source

Member repositories

RepositoryRoleHealth v2
spf13/aferomain76

For agents

markdown · JSON · MCP: product_card(name="spf13/afero")

Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem