Visibility
Control what code is public and what stays private, with path-based rules and automatic mirroring to open-source repositories.
The Problem
Modern projects often have a mix of public and private content. You want to open-source your library code, documentation, and tests, but keep your internal planning documents, proprietary algorithms, and AI configurations private. Traditional approaches force you to choose:
- Separate repositories — painful to keep in sync, code duplication, broken imports
- Everything public — leaks internal strategy, plans, and proprietary code
- Everything private — no community contributions, no portfolio visibility
The Solution
EZKeel introduces path-based visibility rules. In your workspace.yaml, you declare exactly which paths are public and which are private:
The default: private setting means any file not matched by public_paths stays private. Explicit private_paths act as a safety net — even if the default changes, these paths are always excluded.
Publishing
The ezkeel publish command reads these rules, copies only the public paths to a temporary directory, and force-pushes the result to your public repository:
Automatic Mirroring
You can automate the publish step with a Forgejo Action that runs on every push to main:
This ensures your public mirror is always up to date without manual intervention.
How It Works
The publish process follows five steps:
Read Rules
EZKeel reads visibility.public_paths and visibility.private_paths from workspace.yaml.
Walk the Repository
It walks every file in the current directory (skipping .git), checking each path against the visibility rules.
Copy Public Files
Files matching public_paths (and not matching private_paths) are copied to a temporary directory, preserving directory structure.
Create a Git Commit
The temporary directory is initialized as a Git repo, and all files are committed with a "publish: update public mirror" message.
Force Push
The commit is force-pushed to the main branch of the public repository, completely replacing its contents with the filtered snapshot.
Important: The public repository is a mirror, not a fork. It is completely overwritten on each publish. Do not make direct commits to the public repo — they will be lost on the next publish.