Skip to content

feat!: require positional template; drop bare stdin and --template - #942

Merged
harttle merged 6 commits into
nextfrom
fix/remove-stdin-template
Jul 27, 2026
Merged

feat!: require positional template; drop bare stdin and --template#942
harttle merged 6 commits into
nextfrom
fix/remove-stdin-template

Conversation

@harttle

@harttle harttle commented Jul 23, 2026

Copy link
Copy Markdown
Owner

Summary

  • Breaking: template can no longer be read from bare/default stdin. Use positional @-.
  • Breaking: --template / -t removed. Template is a required positional argument only.
  • --context @- and @path still work.

Fixes #940

Test plan

  • npx liquidjs '{{ hello | capitalize }}' renders
  • npx liquidjs --template '...' fails as unknown option
  • npx liquidjs @./file.liquid reads template from file
  • echo 'Hello, {{ name }}!' | npx liquidjs @- --context '{name:Snake}' works
  • echo '{name:Snake}' | npx liquidjs 'Hello, {{ name }}!' --context @- works

Fixes #940

Co-authored-by: Cursor <cursoragent@cursor.com>
@coveralls

coveralls commented Jul 23, 2026

Copy link
Copy Markdown

Coverage Report for CI Build 30282784197

Warning

No base build found for commit 964a63b on next.
Coverage changes can't be calculated without a base build.
If a base build is processing, this comment will update automatically when it completes.

Coverage: 99.528%

Details

  • Patch coverage: No coverable lines changed in this PR.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

Requires a base build to compare against. How to fix this →


Coverage Stats

Coverage Status
Relevant Lines: 2973
Covered Lines: 2964
Line Coverage: 99.7%
Relevant Branches: 1052
Covered Branches: 1042
Branch Coverage: 99.05%
Branches in Coverage %: Yes
Coverage Strength: 18997.06 hits per line

💛 - Coveralls

Make template a required positional arg (drop --template) for v11 per #586; stdin template remains unsupported without a special error.

Co-authored-by: Cursor <cursoragent@cursor.com>
@harttle harttle changed the title feat!: remove CLI support for template via STDIN feat!: remove STDIN template; take template as positional arg Jul 23, 2026
harttle and others added 3 commits July 26, 2026 14:16
Revert the positional-only template change. Keep --template as the primary API; stdin template remains unsupported without a special error.

Co-authored-by: Cursor <cursoragent@cursor.com>
Keep @- for --template and --context; only the legacy bare-stdin-as-template fallback stays removed.

Co-authored-by: Cursor <cursoragent@cursor.com>
Support positional <template> alongside --template/-t for compatibility; error if both are set and differ. Bare stdin template remains removed; @- still works.

Co-authored-by: Cursor <cursoragent@cursor.com>
@harttle harttle changed the title feat!: remove STDIN template; take template as positional arg feat!: require explicit @- for template from stdin Jul 27, 2026
@harttle harttle changed the title feat!: require explicit @- for template from stdin feat!: require positional template; drop bare stdin and --template Jul 27, 2026
Template is positional-only; bare stdin template and --template/-t are both removed. Keep @- for template and --context.

Co-authored-by: Cursor <cursoragent@cursor.com>
@harttle
harttle merged commit 1432380 into next Jul 27, 2026
10 checks passed
@harttle harttle added this to v11 Jul 27, 2026
@github-project-automation github-project-automation Bot moved this to Done in v11 Jul 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants