Skip to content

Conversation

@cjbell
Copy link
Contributor

@cjbell cjbell commented Nov 3, 2025

Description

This PR adds project configuration support to the Knock CLI through a knock.json file. The implementation includes:

  1. A new init command that creates a knock.json configuration file in the current directory
  2. Project configuration that stores the location of Knock resources (knockDir)
  3. Updated resource commands to use the configured knock directory when no explicit directory flag is provided
  4. Helper functions to resolve resource directories within the knock directory

This change improves the developer experience by eliminating the need to specify the --knock-dir flag with every command, allowing for a more streamlined workflow when working with Knock resources.

Tasks

KNO-10385

@linear
Copy link

linear bot commented Nov 3, 2025

Copy link
Contributor Author

cjbell commented Nov 3, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@cjbell cjbell marked this pull request as ready for review November 3, 2025 01:13
@cjbell cjbell force-pushed the cjbell-kno-10385-cli-introduce-knock-init-and-knockjson-file branch 3 times, most recently from b80d410 to 6ef4296 Compare November 3, 2025 01:25
Copy link
Contributor

@MikeCarbone MikeCarbone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small comment but looks good otherwise, lfg!

Copy link
Contributor

@mattmikolay mattmikolay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great! 👏🏻

Copy link
Contributor

@thomaswhyyou thomaswhyyou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few small things, but it's looking good - thanks for taking a stab at this!

@cjbell cjbell force-pushed the cjbell-kno-10385-cli-introduce-knock-init-and-knockjson-file branch 2 times, most recently from 99af9b0 to 2e785b9 Compare November 4, 2025 03:40
@cjbell cjbell force-pushed the cjbell-kno-10385-cli-introduce-knock-init-and-knockjson-file branch from 2e785b9 to 75788f4 Compare November 4, 2025 03:44
Copy link
Contributor

@thomaswhyyou thomaswhyyou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking really great- left a couple follow up comments/questions but looks pretty close to ship.

@cjbell cjbell requested a review from thomaswhyyou November 8, 2025 15:36
Copy link
Contributor

@thomaswhyyou thomaswhyyou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀🚀🚀

@cjbell cjbell merged commit bc32875 into main Nov 13, 2025
14 of 15 checks passed
@cjbell cjbell deleted the cjbell-kno-10385-cli-introduce-knock-init-and-knockjson-file branch November 13, 2025 19:43
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.

5 participants