Add bakefile - #3281
Open
wislertt wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Project
bakefile
Checklist
Add project-name- [project-name](url) - Description ending with period.Why This Project Is Awesome
Which criterion does it meet? (pick one)
Explain:
bakefile is a task runner where tasks are Python class methods instead of shell recipes, so a task library can be shared across projects and languages.
It sits at 5 stars, under the 100-star threshold for a normal entry. I know the count is low, so I've laid out the case below and would appreciate a fair look.
ctx.run()still runs ordinary CLI commands through subprocess, so it can manage tasks for any language (Go, Rust, JS).bakeCLI has had no breaking changes in months.BaseSettings), and tasks get full--helpand shell completion.The problem it solves
We all have a task like this. My
bake lintfor a Python repo runs a fixed sequence:I was pasting that into every Python repo. The prettier and actionlint lines are identical everywhere, but the middle is Python-specific, and a Rust repo swaps it for
cargo fmt/cargo clippy. With bakefile that sequence lives in one base class, and each repo inherits it and overrides only the language-specific part.How It Differs
Task reusability via class inheritance. Most task runners are either a DSL (Make, Just) or flat functions with no inheritance model (invoke, doit). I searched for a runner like this for months before giving up and building bakefile, because I could not find one where tasks are class methods you inherit and override. Shared task libraries compose through normal Python inheritance, which none of the other runners do. That reuse is also how I actually maintain the project, pulling the generalizable parts of my task modules into shared, inheritable libraries that ship inside the package itself.