Skip to content

kettle-rb/kettle-jem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

101 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Galtzo FLOSS Logo by Aboling0, CC BY-SA 4.0 ruby-lang Logo, Yukihiro Matsumoto, Ruby Visual Identity Team, CC BY-SA 2.5 kettle-rb Logo by Aboling0, CC BY-SA 4.0

☯️ Kettle::Jem

Version GitHub tag (latest SemVer) License: MIT Downloads Rank Open Source Helpers CodeCov Test Coverage Coveralls Test Coverage QLTY Test Coverage QLTY Maintainability CI Heads CI Runtime Dependencies @ HEAD CI Current Deps Locked Deps Unlocked CI Supported CI Test Coverage CI Style CodeQL Apache SkyWalking Eyes License Compatibility Check

if ci_badges.map(&:color).detect { it != "green"} ☝️ let me know, as I may have missed the discord notification.


if ci_badges.map(&:color).all? { it == "green"} 👇️ send money so I can do more of this. FLOSS maintenance is now my full-time job.

OpenCollective Backers OpenCollective Sponsors Sponsor Me on Github Liberapay Goal Progress Donate on PayPal Buy me a coffee Donate on Polar Donate at ko-fi.com

👣 How will this project approach the September 2025 hostile takeover of RubyGems? 🚑️

I've summarized my thoughts in this blog post.

🌻 Synopsis

A collection of Ast::Merge::MergerConfig presets, YAML-based merge recipes, signature generators, and node typing classifiers for gem templating with the *-merge gem family.

The *-merge Gem Family

The *-merge gem family provides intelligent, AST-based merging for various file formats. At the foundation is tree_haver, which provides a unified cross-Ruby parsing API that works seamlessly across MRI, JRuby, and TruffleRuby.

Gem Version / CI Language
/ Format
Parser Backend(s) Description
tree_haver Version
CI
Multi Supported Backends: MRI C, Rust, FFI, Java, Prism, Psych, Commonmarker, Markly, Citrus, Parslet Foundation: Cross-Ruby adapter for parsing libraries (like Faraday for HTTP)
ast-merge Version
CI
Text internal Infrastructure: Shared base classes and merge logic for all *-merge gems
bash-merge Version
CI
Bash tree-sitter-bash (via tree_haver) Smart merge for Bash scripts
commonmarker-merge Version
CI
Markdown Commonmarker (via tree_haver) Smart merge for Markdown (CommonMark via comrak Rust)
dotenv-merge Version
CI
Dotenv internal Smart merge for .env files
json-merge Version
CI
JSON tree-sitter-json (via tree_haver) Smart merge for JSON files
jsonc-merge Version
CI
JSONC tree-sitter-jsonc (via tree_haver) ⚠️ Proof of concept; Smart merge for JSON with Comments
markdown-merge Version
CI
Markdown Commonmarker / Markly (via tree_haver), Parslet Foundation: Shared base for Markdown mergers with inner code block merging
markly-merge Version
CI
Markdown Markly (via tree_haver) Smart merge for Markdown (CommonMark via cmark-gfm C)
prism-merge Version
CI
Ruby Prism (prism std lib gem) Smart merge for Ruby source files
psych-merge Version
CI
YAML Psych (psych std lib gem) Smart merge for YAML files
rbs-merge Version
CI
RBS tree-sitter-rbs (via tree_haver), RBS (rbs std lib gem) Smart merge for Ruby type signatures
toml-merge Version
CI
TOML Parslet + toml, Citrus + toml-rb, tree-sitter-toml (all via tree_haver) Smart merge for TOML files

Backend Platform Compatibility

tree_haver supports multiple parsing backends, but not all backends work on all Ruby platforms:

Platform 👉️
TreeHaver Backend 👇️
MRI JRuby TruffleRuby Notes
MRI (ruby_tree_sitter) C extension, MRI only
Rust (tree_stump) Rust extension via magnus/rb-sys, MRI only
FFI (ffi) TruffleRuby's FFI doesn't support STRUCT_BY_VALUE
Java (jtreesitter) JRuby only, requires grammar JARs
Prism (prism) Ruby parsing, stdlib in Ruby 3.4+
Psych (psych) YAML parsing, stdlib
Citrus (citrus) Pure Ruby PEG parser, no native dependencies
Parslet (parslet) Pure Ruby PEG parser, no native dependencies
Commonmarker (commonmarker) Rust extension for Markdown (via commonmarker-merge)
Markly (markly) C extension for Markdown (via markly-merge)

Legend: ✅ = Works, ❌ = Does not work, ❓ = Untested

Why some backends don't work on certain platforms:

  • JRuby: Runs on the JVM; cannot load native C/Rust extensions (.so files)
  • TruffleRuby: Has C API emulation via Sulong/LLVM, but it doesn't expose all MRI internals that native extensions require (e.g., RBasic.flags, rb_gc_writebarrier)
  • FFI on TruffleRuby: TruffleRuby's FFI implementation doesn't support returning structs by value, which tree-sitter's C API requires

Example implementations for the gem templating use case:

Gem Purpose Description
kettle-dev Gem Development Development tooling, CI automation, and release workflows
kettle-jem Gem Templating Gem template library with smart merge support

💡 Info you can shake a stick at

Tokens to Remember Gem name Gem namespace
Works with MRI Ruby 3 Ruby 3.2 Compat Ruby 3.3 Compat Ruby 3.4 Compat Ruby HEAD Compat
Support & Community Join Me on Daily.dev's RubyFriends Live Chat on Discord Get help from me on Upwork Get help from me on Codementor
Source Source on GitLab.com Source on CodeBerg.org Source on Github.com The best SHA: dQw4w9WgXcQ!
Documentation Current release on RubyDoc.info YARD on Galtzo.com Maintainer Blog GitLab Wiki GitHub Wiki
Compliance License: MIT Compatible with Apache Software Projects: Verified by SkyWalking Eyes 📄ilo-declaration-img Security Policy Contributor Covenant 2.1 SemVer 2.0.0
Style Enforced Code Style Linter Keep-A-Changelog 1.0.0 Gitmoji Commits Compatibility appraised by: appraisal2
Maintainer 🎖️ Follow Me on LinkedIn Follow Me on Ruby.Social Follow Me on Bluesky Contact Maintainer My technical writing
... 💖 Find Me on WellFound: Find Me on CrunchBase My LinkTree More About Me 🧊 🐙 🛖 🧪

Compatibility

Compatible with MRI Ruby 3.2.0+. Due to constraints of dependencies it will not install on JRuby or TruffleRuby.

🚚 Amazing test matrix was brought to you by 🔎 appraisal2 🔎 and the color 💚 green 💚
👟 Check it out! github.com/appraisal-rb/appraisal2

Federated DVCS

Find this repo on federated forges (Coming soon!)
Federated DVCS Repository Status Issues PRs Wiki CI Discussions
🧪 kettle-rb/kettle-jem on GitLab The Truth 💚 💚 💚 🐭 Tiny Matrix
🧊 kettle-rb/kettle-jem on CodeBerg An Ethical Mirror (Donate) 💚 💚 ⭕️ No Matrix
🐙 kettle-rb/kettle-jem on GitHub Another Mirror 💚 💚 💚 💯 Full Matrix 💚
🎮️ Discord Server Live Chat on Discord Let's talk about this library!

Enterprise Support Tidelift

Available as part of the Tidelift Subscription.

Need enterprise-level guarantees?

The maintainers of this and thousands of other packages are working with Tidelift to deliver commercial support and maintenance for the open source packages you use to build your applications. Save time, reduce risk, and improve code health, while paying the maintainers of the exact packages you use.

Get help from me on Tidelift

  • 💡Subscribe for support guarantees covering all your FLOSS dependencies

  • 💡Tidelift is part of Sonar

  • 💡Tidelift pays maintainers to maintain the software you depend on!
    📊@Pointy Haired Boss: An enterprise support subscription is "never gonna let you down", and supports open source maintainers Alternatively:

  • Live Chat on Discord

  • Get help from me on Upwork

  • Get help from me on Codementor

✨ Installation

Install the gem and add to the application's Gemfile by executing:

bundle add kettle-jem

If bundler is not being used to manage dependencies, install the gem by executing:

gem install kettle-jem

🔒 Secure Installation

For Medium or High Security Installations

This gem is cryptographically signed, and has verifiable SHA-256 and SHA-512 checksums by stone_checksums. Be sure the gem you install hasn’t been tampered with by following the instructions below.

Add my public key (if you haven’t already, expires 2045-04-29) as a trusted certificate:

gem cert --add <(curl -Ls https://raw.github.com/galtzo-floss/certs/main/pboling.pem)

You only need to do that once. Then proceed to install with:

gem install kettle-jem -P HighSecurity

The HighSecurity trust profile will verify signed gems, and not allow the installation of unsigned dependencies.

If you want to up your security game full-time:

bundle config set --global trust-policy MediumSecurity

MediumSecurity instead of HighSecurity is necessary if not all the gems you use are signed.

NOTE: Be prepared to track down certs for signed gems and add them the same way you added mine.

⚙️ Configuration

Kettle::Jem provides two complementary systems for merge configuration:

  1. Presets (Ruby classes) — Programmatic API with factory methods for in-process use
  2. Recipes (YAML files) — Distributable, declarative merge configurations that any project can ship and any *-merge consumer can load without additional Ruby instrumentation

Presets

Presets are Ruby classes under Kettle::Jem::Presets::* that provide factory methods for creating Ast::Merge::MergerConfig objects. Each preset bundles a signature generator, node typing configuration, and freeze token appropriate for its file type. kettle-dev uses presets internally to power its gem templating workflow.

Available Presets

Preset File Types Merger Signature Matching Node Typing
Presets::Gemfile Gemfile, *.gemfile prism-merge gem() by name, source() singleton, eval_gemfile() by path, git_source() by name, ruby() singleton Gem categorization (lint/test/doc/dev)
Presets::Appraisals Appraisals prism-merge Extends Gemfile + appraise() by name Appraisal categorization (ruby_version/deps/feature/runtime)
Presets::Gemspec *.gemspec prism-merge spec.*= by attribute, add_dependency by gem name, Gem::Specification.new singleton Attribute categorization (identity/metadata/files/deps/requirements)
Presets::Rakefile Rakefile, *.rake prism-merge task() by name, namespace() by name, desc() singleton Task categorization (build/test/release/lint/doc)
Presets::Markdown *.md markly-merge Headings by level+text, tables by header, code blocks by language
Presets::Yaml *.yml, *.yaml psych-merge Key-based (internal to psych-merge)
Presets::Json *.json json-merge Key-based (internal to json-merge)
Presets::Rbs *.rbs rbs-merge Declaration-based (internal to rbs-merge)
Presets::Dotenv .env* dotenv-merge Variable name matching (internal to dotenv-merge)

Each preset provides three factory methods:

  • destination_wins — Preserve destination customizations; template-only content is skipped
  • template_wins — Apply template updates; template-only content is added
  • custom — Full control over preference, add_template_only, freeze_token, and node_typing

Recipes

Recipes are self-contained YAML files designed to be distributable units of merge knowledge. A project can ship a recipe alongside its templates, allowing any consumer of the *-merge gem family to perform intelligent merges without writing Ruby merge logic.

A simple recipe is just a YAML file — no companion folder or Ruby scripts required:

name: my_config
description: Merge YAML config files with destination preference
parser: psych
merge:
  preference: destination
  add_missing: true
freeze_token: my-project

For advanced recipes that need custom signature matching or node categorization, a companion folder can optionally contain small Ruby scripts (signature generators, node typing lambdas) that are loaded on demand. The consumer only needs ast-merge to load and use them.

Available Recipes

Recipe YAML File Parser Description
:gemfile recipes/gemfile.yml prism Gemfile merging with gem-name-aware signature matching and gem categorization node typing
:gemspec recipes/gemspec.yml prism Gemspec merging with attribute assignment and dependency matching
:rakefile recipes/rakefile.yml prism Rakefile merging with task/namespace/require matching
:appraisals recipes/appraisals.yml prism Appraisals merging extending Gemfile signatures with appraise() block matching
:markdown recipes/markdown.yml markly Markdown merging with heading, table, and code block matching

Recipe YAML Schema

Each recipe YAML defines:

  • name — Recipe identifier
  • description — Human-readable description
  • parser — Which *-merge parser to use (prism, markly, etc.)
  • merge.preference — Default merge preference (:template or :destination)
  • merge.add_missing — Whether to add template-only nodes to the result
  • merge.signature_generator — Path to companion Ruby script (relative to recipe folder)
  • merge.node_typing — Hash mapping node class names to companion Ruby scripts
  • freeze_token — Token for freeze block preservation

Shipping Your Own Recipes

Any project can create and distribute recipes. A minimal recipe is a single YAML file:

my - project /
  recipes /
  my_format.yml

For recipes that need custom signature matching or node categorization, add a companion folder with Ruby scripts. The folder name must match the recipe name (without the .yml extension):

my - project /
  recipes /
  my_format.yml
    my_format/                     # Optional companion folder
      signature_generator.rb       # Returns a lambda for node matching
      typing /
        call_node.rb               # Returns a lambda for node categorization

Then consumers load it directly:

preset = Ast::Merge::Recipe::Preset.load("path/to/my_format.yml")
merger = Prism::Merge::SmartMerger.new(template, destination, **preset.to_h)
result = merger.merge

No dependency on kettle-jem is required — only ast-merge and the appropriate *-merge gem for parsing.

Freeze Token

The default freeze token for kettle-jem is kettle-jem. This means freeze markers look like:

# kettle-jem:freeze
# ... content to preserve ...
# kettle-jem:unfreeze

Freeze Blocks in Ruby Files

When using kettle-jem's merge configurations with Ruby files (gemspecs, Gemfiles, etc.), you can protect sections from being overwritten by the template using freeze markers.

Block-Style Freeze (with matching markers)

# kettle-jem:freeze
gem "my-custom-gem", path: "../local-fork"
gem "another-local-gem", git: "https://github.com/my-org/gem.git"
# kettle-jem:unfreeze

Inline Freeze Comments

You can also freeze a single Ruby statement by placing a freeze comment immediately before it:

# kettle-jem:freeze
gem "my-custom-gem", "~> 1.0"

⚠️ Important: When a freeze comment precedes a block-based statement (like a class, module, method definition, or DSL block), the entire block is frozen, preventing any template updates to that section:

# kettle-jem:freeze
class MyCustomClass
  # EVERYTHING inside this class is frozen!
  # Template changes to this class will be ignored.
  def custom_method
    # ...
  end
end

# kettle-jem:freeze
Gem::Specification.new do |spec|
  # The entire gemspec block is frozen
  # Use this carefully - it prevents ALL template updates!
end

Matching Behavior

Frozen statements are matched by their structural identity, not their content:

  • A frozen gem "example" matches gem "example" in the template (by gem name)
  • A frozen spec.add_dependency "foo" matches the same dependency in the template
  • A frozen class Foo matches class Foo in the template (by class name) The destination's frozen version is always preserved, regardless of changes in the template.

Template Manifest and AST Strategies

kettle:jem:template looks at .kettle-jem.yml to determine how each file should be updated. The config supports a hybrid format: a list of ordered glob patterns used as fallbacks and a files nested map for per-file configurations. Each entry ultimately exposes a strategy (and optional merge options for Ruby files).

Strategy Behavior
skip Legacy behavior: template content is copied with token replacements and any bespoke merge logic already in place.
replace Template AST replaces the destination outside of kettle-jem:freeze sections.
append Only missing AST nodes (e.g., gem or task declarations) are appended; existing nodes remain untouched.
merge Destination nodes are updated in-place using the template AST (used for Gemfile, *.gemspec, and Rakefile).

All Ruby files receive this reminder (inserted after shebang/frozen-string-literal lines):

# To force retention during kettle-jem templating:
#     kettle-jem:freeze
#     # ... your code
#     kettle-jem:unfreeze

Wrap any code you never want rewritten between kettle-jem:freeze / kettle-jem:unfreeze comments. When an AST merge fails, the task emits an error asking you to file an issue at https://github.com/kettle-rb/kettle-jem/issues and then aborts—there is no regex fallback.

Template .example files are preferred

  • The templating step dynamically prefers any *.example file present in this gem's templates. When a *.example exists alongside the non-example template, the .example content is used, and the destination file is written without the .example suffix.
  • This applies across all templated files, including:
    • Root files like .gitlab-ci.yml (copied from .gitlab-ci.yml.example when present).
    • Nested files like .github/workflows/coverage.yml (copied from .github/workflows/coverage.yml.example when present).
  • This behavior is automatic for any future *.example files added to the templates.
  • Exception: .env.local is handled specially for safety. Regardless of whether the template provides .env.local or .env.local.example, the installer copies it to .env.local.example in your project, and will never create or overwrite .env.local.

Template Config Example

Here is an example .kettle-jem.yml (hybrid format):

# Defaults applied to per-file merge options when strategy: merge
defaults:
  preference: "template"
  add_template_only_nodes: true

# Ordered glob patterns (first match wins)
patterns:
  - path: "*.gemspec"
    strategy: merge
  - path: "gemfiles/modular/erb/**"
    strategy: merge
  - path: ".github/**/*.yml"
    strategy: skip

# Per-file nested configuration (overrides patterns)
files:
  "Gemfile":
    strategy: merge
    add_template_only_nodes: true

  "Rakefile":
    strategy: merge

  "README.md":
    strategy: replace

  ".env.local":
    strategy: skip

🔧 Basic Usage

The kettle-jem command

kettle-jem ships a single executable, kettle-jem, that bootstraps a host gem repository to use kettle-jem tooling. Run it from inside the target gem's repository working directory.

kettle-jem [options]
# e.g., kettle-jem --allowed=true --force

What it does

The kettle-jem command performs the following steps in order:

  1. Prechecks — Verifies you're inside a git repo with a clean working tree, a gemspec, and a Gemfile
  2. Sync dev dependencies — Updates your gemspec's add_development_dependency entries to match the kettle-jem template
  3. Sync Gemfile — Ensures your Gemfile contains required source, git_source, gemspec, and eval_gemfile directives from the template
  4. Sync modular gemfiles — Copies gemfiles/modular/*.gemfile files from the template
  5. Ensure bin/setup — Copies bin/setup from the template if missing
  6. Ensure Rakefile — Replaces your Rakefile with the kettle-jem template Rakefile
  7. Run bin/setup — Executes bin/setup to install dependencies
  8. Generate binstubs — Runs bundle binstubs --all
  9. Commit bootstrap changes — Commits any changes from the above steps
  10. Run kettle:jem:install — Invokes the full template merge via rake kettle:jem:install, which performs AST-based smart merging of all template files according to .kettle-jem.yml

Options

All options are passed through to the underlying rake kettle:jem:install task:

Option Description
--allowed=VAL Acknowledge prior direnv allow, etc. Passed as allowed=VAL to the rake task.
--force Accept all prompts non-interactively (sets force=true). Useful for CI or scripted setups.
--hook_templates=VAL Control git hook templating. Values: local (install to .git/hooks), global (install to ~/.git-templates), skip (do not install hooks).
--only=VAL Restrict install scope to a specific subset of files.
--include=VAL Include optional files by glob pattern.
-h, --help Show help and exit.

Environment variables

Variable Description
DEBUG=true Print full backtraces on errors
FUNDING_ORG=org_name Override the GitHub org used for FUNDING.yml generation. Auto-derived from git remote origin when not set. Set to false to disable.

Examples

Bootstrap a new gem repository with all defaults (interactive prompts):

cd my-gem
kettle-jem

Non-interactive setup for CI:

kettle-jem --force

Only install git hooks locally:

kettle-jem --hook_templates=local

Rake tasks

After initial setup, the following rake tasks are available for ongoing use:

Task Description
rake kettle:jem:install Full template merge (same as what kettle-jem runs at the end)
rake kettle:jem:template File templating only (AST-based smart merge of all template files)
rake kettle:jem:selftest Validate that templating kettle-jem against itself produces expected output

Using Presets

Presets are the programmatic Ruby API, used by kettle-dev for in-process gem templating:

require "kettle/jem"

# Merge a Gemfile with template preference
config = Kettle::Jem::Presets::Gemfile.template_wins
merger = Prism::Merge::SmartMerger.new(template_content, destination_content, **config.to_h)
result = merger.merge

# Merge a gemspec preserving destination customizations
config = Kettle::Jem::Presets::Gemspec.destination_wins(freeze_token: "my-project")
merger = Prism::Merge::SmartMerger.new(template_content, destination_content, **config.to_h)
result = merger.merge

# Merge Markdown with template priority
config = Kettle::Jem::Presets::Markdown.template_wins
merger = Markly::Merge::SmartMerger.new(template_content, destination_content, **config.to_h)
result = merger.merge

# Custom merge with per-type preferences
config = Kettle::Jem::Presets::Gemspec.custom(
  preference: {
    default: :destination,
    spec_metadata: :template,  # Update metadata from template
  },
  add_template_only: true,
  freeze_token: "kettle-dev",
)
merger = Prism::Merge::SmartMerger.new(template_content, destination_content, **config.to_h)
result = merger.merge

Using Recipes

Recipes provide a declarative, distributable approach to merge configuration. A project ships a recipe YAML (and companion scripts), and consumers load it without needing to write merge instrumentation in Ruby:

require "kettle/jem"

# Load a built-in recipe by name
preset = Kettle::Jem.recipe(:gemfile)

# Use it with a SmartMerger
merger = Prism::Merge::SmartMerger.new(
  template_content,
  destination_content,
  **preset.to_h,
)
result = merger.merge

# List available built-in recipes
Kettle::Jem.available_recipes  # => [:appraisals, :gemfile, :gemspec, :markdown, :rakefile]

# Load a recipe from any path (no kettle-jem dependency needed — only ast-merge)
preset = Ast::Merge::Recipe::Preset.load("/path/to/third-party/recipe.yml")
merger = Prism::Merge::SmartMerger.new(template, destination, **preset.to_h)
result = merger.merge

🦷 FLOSS Funding

While kettle-rb tools are free software and will always be, the project would benefit immensely from some funding. Raising a monthly budget of... "dollars" would make the project more sustainable.

We welcome both individual and corporate sponsors! We also offer a wide array of funding channels to account for your preferences (although currently Open Collective is our preferred funding platform).

If you're working in a company that's making significant use of kettle-rb tools we'd appreciate it if you suggest to your company to become a kettle-rb sponsor.

You can support the development of kettle-rb tools via GitHub Sponsors, Liberapay, PayPal, Open Collective and Tidelift.

📍 NOTE
If doing a sponsorship in the form of donation is problematic for your company
from an accounting standpoint, we'd recommend the use of Tidelift,
where you can get a support-like subscription instead.

Open Collective for Individuals

Support us with a monthly donation and help us continue our activities. [Become a backer]

NOTE: kettle-readme-backers updates this list every day, automatically.

No backers yet. Be the first!

Open Collective for Organizations

Become a sponsor and get your logo on our README on GitHub with a link to your site. [Become a sponsor]

NOTE: kettle-readme-backers updates this list every day, automatically.

No sponsors yet. Be the first!

Another way to support open-source

I’m driven by a passion to foster a thriving open-source community – a space where people can tackle complex problems, no matter how small. Revitalizing libraries that have fallen into disrepair, and building new libraries focused on solving real-world challenges, are my passions. I was recently affected by layoffs, and the tech jobs market is unwelcoming. I’m reaching out here because your support would significantly aid my efforts to provide for my family, and my farm (11 🐔 chickens, 2 🐶 dogs, 3 🐰 rabbits, 8 🐈‍ cats).

If you work at a company that uses my work, please encourage them to support me as a corporate sponsor. My work on gems you use might show up in bundle fund.

I’m developing a new library, floss_funding, designed to empower open-source developers like myself to get paid for the work we do, in a sustainable way. Please give it a look.

Floss-Funding.dev: 👉️ No network calls. 👉️ No tracking. 👉️ No oversight. 👉️ Minimal crypto hashing. 💡 Easily disabled nags

OpenCollective Backers OpenCollective Sponsors Sponsor Me on Github Liberapay Goal Progress Donate on PayPal Buy me a coffee Donate on Polar Donate to my FLOSS efforts at ko-fi.com Donate to my FLOSS efforts using Patreon

🔐 Security

See SECURITY.md.

🤝 Contributing

If you need some ideas of where to help, you could work on adding more code coverage, or if it is already 💯 (see below) check reek, issues, or PRs, or use the gem and think about how it could be better.

We Keep A Changelog so if you make changes, remember to update it.

See CONTRIBUTING.md for more detailed instructions.

🚀 Release Instructions

See CONTRIBUTING.md.

Code Coverage

Coverage Graph

Coveralls Test Coverage

QLTY Test Coverage

🪇 Code of Conduct

Everyone interacting with this project's codebases, issue trackers, chat rooms and mailing lists agrees to follow the Contributor Covenant 2.1.

🌈 Contributors

Contributors

Made with contributors-img.

Also see GitLab Contributors: https://gitlab.com/kettle-rb/kettle-jem/-/graphs/main

⭐️ Star History Star History Chart

📌 Versioning

This Library adheres to Semantic Versioning 2.0.0. Violations of this scheme should be reported as bugs. Specifically, if a minor or patch version is released that breaks backward compatibility, a new version should be immediately released that restores compatibility. Breaking changes to the public API will only be introduced with new major versions.

dropping support for a platform is both obviously and objectively a breaking change
—Jordan Harband (@ljharb, maintainer of SemVer) in SemVer issue 716

I understand that policy doesn't work universally ("exceptions to every rule!"), but it is the policy here. As such, in many cases it is good to specify a dependency on this library using the Pessimistic Version Constraint with two digits of precision.

For example:

spec.add_dependency("kettle-jem", "~> 1.0")
📌 Is "Platform Support" part of the public API? More details inside.

SemVer should, IMO, but doesn't explicitly, say that dropping support for specific Platforms is a breaking change to an API, and for that reason the bike shedding is endless.

To get a better understanding of how SemVer is intended to work over a project's lifetime, read this article from the creator of SemVer:

See CHANGELOG.md for a list of releases.

📄 License

The gem is available as open source under the terms of the MIT License License: MIT. See LICENSE.txt for the official Copyright Notice.

© Copyright

  • Copyright (c) 2025 - 2026 Peter H. Boling, of Galtzo.com Galtzo.com Logo (Wordless) by Aboling0, CC BY-SA 4.0 , and kettle-jem contributors.

🤑 A request for help

Maintainers have teeth and need to pay their dentists. After getting laid off in an RIF in March, and encountering difficulty finding a new one, I began spending most of my time building open source tools. I'm hoping to be able to pay for my kids' health insurance this month, so if you value the work I am doing, I need your support. Please consider sponsoring me or the project.

To join the community or get help 👇️ Join the Discord.

Live Chat on Discord

To say "thanks!" ☝️ Join the Discord or 👇️ send money.

Sponsor kettle-rb/kettle-jem on Open Source Collective 💌 Sponsor me on GitHub Sponsors 💌 Sponsor me on Liberapay 💌 Donate on PayPal

Please give the project a star ⭐ ♥.

Thanks for RTFM. ☺️

About

☯️ A collection of ast-merge recipes, and token-resolver configs for gem templating.

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors