Skip to content

[6/9] feat: add SCCACHE_FILE_CLONE_COMPRESS for post-write compression#9

Open
mmastrac wants to merge 1 commit intovercel/file-clone-reflinkfrom
vercel/file-clone-compress
Open

[6/9] feat: add SCCACHE_FILE_CLONE_COMPRESS for post-write compression#9
mmastrac wants to merge 1 commit intovercel/file-clone-reflinkfrom
vercel/file-clone-compress

Conversation

@mmastrac
Copy link
Copy Markdown
Collaborator

Summary

  • New env var SCCACHE_FILE_CLONE_COMPRESS specifies a command to run on each cache entry directory after writing (when SCCACHE_FILE_CLONE=true)
  • The entry directory path is appended to the command
  • Command is parsed with shlex for proper quoting support
  • Runs in the background, failures are silently ignored
  • Example: SCCACHE_FILE_CLONE_COMPRESS="applesauce compress -c lzfse" applies APFS transparent compression on macOS

Stack: 6/8

@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch from b668492 to c779b68 Compare March 31, 2026 18:03
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch 2 times, most recently from e49e0d7 to 52be489 Compare March 31, 2026 18:23
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch 2 times, most recently from 226e9df to c3ebfff Compare March 31, 2026 22:05
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch 2 times, most recently from 4801769 to 7991e34 Compare April 1, 2026 18:01
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch 2 times, most recently from 2afce2b to f12d053 Compare April 1, 2026 20:55
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch from 7991e34 to 82cae86 Compare April 1, 2026 20:55
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch from f12d053 to 136498c Compare April 1, 2026 21:02
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch 2 times, most recently from 822f6cc to 5055c36 Compare April 2, 2026 00:52
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch from 136498c to 4be87c8 Compare April 2, 2026 00:52
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch from 5055c36 to 614ab48 Compare April 2, 2026 16:22
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch 2 times, most recently from 0106a7d to ddb7117 Compare April 2, 2026 16:24
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch 2 times, most recently from 3b1c8b7 to c2dfa44 Compare April 2, 2026 16:29
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch from ddb7117 to eed7dde Compare April 2, 2026 16:29
@mmastrac mmastrac changed the title [5/7] feat: add SCCACHE_FILE_CLONE_COMPRESS for post-write compression [6/9] feat: add SCCACHE_FILE_CLONE_COMPRESS for post-write compression Apr 2, 2026
When SCCACHE_FILE_CLONE=true, users can set SCCACHE_FILE_CLONE_COMPRESS
to a command that will be spawned on each cache entry directory after
writing. The entry directory path is appended to the command.

Example: SCCACHE_FILE_CLONE_COMPRESS="applesauce compress -c lzfse"
applies APFS transparent compression on macOS, reducing cache disk
usage while keeping files transparently readable and reflink-capable.

The command runs in the background and failures are silently ignored.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@mmastrac mmastrac force-pushed the vercel/file-clone-compress branch from eed7dde to f7e3b82 Compare April 2, 2026 17:18
@mmastrac mmastrac force-pushed the vercel/file-clone-reflink branch from c2dfa44 to 67072e8 Compare April 2, 2026 17:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant