Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cobra #427

Closed
wants to merge 15 commits into from
Closed

cobra #427

wants to merge 15 commits into from

Conversation

brianmcgee
Copy link
Member

@brianmcgee brianmcgee commented Oct 7, 2024

Summary

treefmt.toml has been extended to include an entry for most of the flags that can be passed to treefmt.

In addition, values can now be specified via the environment, prefixed with TREEFMT_.

Finally, the order of precedence for value lookup has been fixed: flag -> env -> treefmt.toml.

On a different note, I imported the more stringent rules for golangci-lint from go-nix and fixed many issues. I started removing globals, but I will leave the cache and format packages for the next few PRs, as I want to review and incorporate some of the work I did in #349.

Changelog

  • fix: git module domain
  • feat: use latest treefmt release for formatting repo
  • feat: create a separate docs devshell
  • feat: simplify .envrc
  • feat: replace kong with cobra/viper
  • feat: simplify devshell
  • chore: update flake inputs
  • feat: more stringent rules for golangci-lint
  • feat: remove globals from stats package

TODO

  • update docs

Closes #351

It was still pointing to git.numtide.com

Signed-off-by: Brian McGee <[email protected]>
Removes dependency on latest build of treefmt from inside the repo.

Signed-off-by: Brian McGee <[email protected]>
Signed-off-by: Brian McGee <[email protected]>
`treefmt.toml` has been extended to include an entry for most of the flags that can be passed to `treefmt`.

In addition, values can now be specified via the environment, prefixed with `TREEFMT_`.

Finally, the order of precedence for value lookup has been fixed: flag -> env -> treefmt.toml.

Closes #351
Signed-off-by: Brian McGee <[email protected]>
Signed-off-by: Brian McGee <[email protected]>
@brianmcgee brianmcgee requested a review from zimbatm October 9, 2024 08:59
@brianmcgee brianmcgee marked this pull request as ready for review October 9, 2024 08:59
Filesystem Type = "filesystem"
Auto Type = iota
Git Type = iota
Filesystem
Copy link
Member

Choose a reason for hiding this comment

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

No Type = iota?

@@ -1,40 +1,17 @@
/*
Copyright © 2024 NAME HERE <EMAIL ADDRESS>
*/
Copy link
Member

Choose a reason for hiding this comment

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

This can be removed

@brianmcgee brianmcgee marked this pull request as draft October 9, 2024 09:51
@brianmcgee
Copy link
Member Author

Decided to break this up into smaller PRs and refine some things.

@brianmcgee brianmcgee closed this Oct 9, 2024
@brianmcgee brianmcgee deleted the cobra branch October 9, 2024 12:23
@brianmcgee brianmcgee restored the cobra branch October 9, 2024 12:23
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.

Allow setting flags as config values
2 participants