-
Notifications
You must be signed in to change notification settings - Fork 4
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
add cli options #24
add cli options #24
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
build.zig
Outdated
@@ -24,6 +24,8 @@ pub fn build(b: *std.Build) void { | |||
.optimize = optimize, | |||
}); | |||
const mod_httpz = httpz.module("httpz"); | |||
const zigcli_dep = b.dependency("zig-cli", .{ .target = target }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{ .optimize = optimize }
?
build.zig.zon
Outdated
@@ -14,5 +14,9 @@ | |||
.url = "https://github.com/karlseguin/http.zig/archive/1a82beb0dfc22e6fc38e9918e323f8fbd3cb78a3.tar.gz", | |||
.hash = "122020cbd399273b1220f11c4b2d734b86c94cc5f1c2d6d90fc766580bc0e25b0dfb", | |||
}, | |||
.@"zig-cli" = .{ | |||
.url = "https://github.com/sam701/zig-cli/archive/ddf49596a9225c91e6cd9c28904aec598d5becf0.tar.gz", | |||
.hash = "1220787d26a153a3755d55c8b65af53f7b1c4d79add4a47e2898dc776f3a16f1ce89", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One less tab?
src/config/config.zig
Outdated
|
||
pub const Config = struct { | ||
engine_port: u16 = 8551, | ||
network_id: u64 = @intFromEnum(ChainId.Mainnet), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Uhm, should we rename ChaindID
enum to NetworkId
?
e8fca1e
to
c7a28ef
Compare
Demonstrate how options can be added easily added.
In order to see the help message, type: