-
Notifications
You must be signed in to change notification settings - Fork 375
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
gnoland start
--config
flag is tied to the flag configuration and not the node config
#1234
Comments
Shall we change it and make it tied to the node config file? This way we could also compromise on the "scriptability" Antonio was worrying about. ie. we can run gnoland like this:
|
To maintain consistency with other command-line interfaces (CLIs), I propose the following approach:
type opts struct {
Verbose bool
OtherFlag string
TM2Config tm2config.Config
} Then, register flags using the prefix You can find more details about this approach in the description provided in issue #731. |
Another approach is to introduce a Subsequently, the |
I am on the fence about this, because I support both of the approaches you've mentioned. I've always utilized specific flags for node configuration, along with support for a config file (you have the file -> env -> flags precedence here, or whatever the order is). The thing I dislike about this approach is that you insanely bloat the start command, which should be mega simple, while giving the user power to configure. What do you think about this, as a compromise:
|
I will open up a PR for implementing this fix, since it's blocking us on some efforts |
## Description This PR adds support for specifying a custom node configuration file using the `--tm2-node-config` flag. Resolves #1234 <details><summary>Contributors' checklist...</summary> - [x] Added new tests, or not needed, or not feasible - [x] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [x] Updated the official documentation or not needed - [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [x] Added references to related issues and PRs - [x] Provided any useful hints for running manual tests - [x] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md). </details>
## Description This PR adds support for specifying a custom node configuration file using the `--tm2-node-config` flag. Resolves gnolang#1234 <details><summary>Contributors' checklist...</summary> - [x] Added new tests, or not needed, or not feasible - [x] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [x] Updated the official documentation or not needed - [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [x] Added references to related issues and PRs - [x] Provided any useful hints for running manual tests - [x] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md). </details>
## Description This PR adds support for specifying a custom node configuration file using the `--tm2-node-config` flag. Resolves gnolang#1234 <details><summary>Contributors' checklist...</summary> - [x] Added new tests, or not needed, or not feasible - [x] Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory - [x] Updated the official documentation or not needed - [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message was included in the description - [x] Added references to related issues and PRs - [x] Provided any useful hints for running manual tests - [x] Added new benchmarks to [generated graphs](https://gnoland.github.io/benchmarks), if any. More info [here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md). </details>
Description
The configuration flag value specified in the
gnoland start
command:gno/gno.land/cmd/gnoland/start.go
Lines 113 to 119 in 52ea535
is actually tied to the
ffcli
config (flag configuration for thegnoland start
command), and not the node configuration:gno/gno.land/cmd/gnoland/root.go
Line 29 in 52ea535
The text was updated successfully, but these errors were encountered: