mod: bump zterm dependency; add zlog dependency
All checks were successful
Zig Project Action / Lint, Spell-check and test zig project (push) Successful in 1m22s
All checks were successful
Zig Project Action / Lint, Spell-check and test zig project (push) Successful in 1m22s
`zlog` is used to log messages to the log file that is also used by `serve` by default, making it a single source for all the log messages.
This commit is contained in:
@@ -4,6 +4,14 @@ pub fn build(b: *std.Build) void {
|
|||||||
const target = b.standardTargetOptions(.{});
|
const target = b.standardTargetOptions(.{});
|
||||||
const optimize = b.standardOptimizeOption(.{});
|
const optimize = b.standardOptimizeOption(.{});
|
||||||
|
|
||||||
|
const zlog = b.dependency("zlog", .{
|
||||||
|
.target = target,
|
||||||
|
.optimize = optimize,
|
||||||
|
.timestamp = false,
|
||||||
|
.stderr = false,
|
||||||
|
.file = "log",
|
||||||
|
});
|
||||||
|
|
||||||
const zterm = b.dependency("zterm", .{
|
const zterm = b.dependency("zterm", .{
|
||||||
.target = target,
|
.target = target,
|
||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
@@ -17,6 +25,7 @@ pub fn build(b: *std.Build) void {
|
|||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
.imports = &.{
|
.imports = &.{
|
||||||
.{ .name = "zterm", .module = zterm.module("zterm") },
|
.{ .name = "zterm", .module = zterm.module("zterm") },
|
||||||
|
.{ .name = "zlog", .module = zlog.module("zlog") },
|
||||||
.{
|
.{
|
||||||
.name = "about",
|
.name = "about",
|
||||||
.module = b.createModule(.{
|
.module = b.createModule(.{
|
||||||
|
|||||||
@@ -6,8 +6,12 @@
|
|||||||
.minimum_zig_version = "0.16.0-dev.463+f624191f9",
|
.minimum_zig_version = "0.16.0-dev.463+f624191f9",
|
||||||
.dependencies = .{
|
.dependencies = .{
|
||||||
.zterm = .{
|
.zterm = .{
|
||||||
.url = "git+https://gitea.yves-biener.de/yves-biener/zterm#89aeac1e968f1390bd945f734aac8612efbab179",
|
.url = "git+https://gitea.yves-biener.de/yves-biener/zterm#c645c2efee5ff57fa6fb2b9f9155cf21723bf085",
|
||||||
.hash = "zterm-0.3.0-1xmmELjzGwBxVlqXRHn7p-sXFU9xPxqFMxF0PY2CkzFn",
|
.hash = "zterm-0.3.0-1xmmEMbzGwD3MiXzgXWwnTEFIjvtWTcQrBLqYS5O00ee",
|
||||||
|
},
|
||||||
|
.zlog = .{
|
||||||
|
.url = "git+https://gitea.yves-biener.de/yves-biener/zlog#411a6dc358a3ef463ab704e2f6b887a019a5decf",
|
||||||
|
.hash = "zlog-0.15.0-6JSlR9tGAAD1_RAwOEDWrSVFRl4t4WFsJxRXqrW1PHfK",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
.paths = .{
|
.paths = .{
|
||||||
|
|||||||
@@ -118,10 +118,12 @@ pub fn main() !void {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub const panic = App.panic_handler;
|
pub const panic = App.panic_handler;
|
||||||
|
pub const std_options = zlog.std_options;
|
||||||
const log = std.log.scoped(.default);
|
const log = std.log.scoped(.default);
|
||||||
|
|
||||||
const std = @import("std");
|
const std = @import("std");
|
||||||
const assert = std.debug.assert;
|
const assert = std.debug.assert;
|
||||||
|
const zlog = @import("zlog");
|
||||||
const zterm = @import("zterm");
|
const zterm = @import("zterm");
|
||||||
const App = zterm.App(
|
const App = zterm.App(
|
||||||
Model,
|
Model,
|
||||||
|
|||||||
Reference in New Issue
Block a user