Compare commits
2 commits
cb9e57492e
...
82b8a679e7
| Author | SHA1 | Date | |
|---|---|---|---|
| 82b8a679e7 | |||
| a97356b2a5 |
3 changed files with 7 additions and 5 deletions
|
|
@ -6,8 +6,8 @@
|
||||||
|
|
||||||
.dependencies = .{
|
.dependencies = .{
|
||||||
.syntax = .{
|
.syntax = .{
|
||||||
.url = "git+https://github.com/neurocyte/flow-syntax?ref=master#5c8b804defff9f98a367adca1008c8d4e5945053",
|
.url = "git+https://github.com/neurocyte/flow-syntax?ref=master#880eac1a7ef51da53ae5116d69623169e74942fc",
|
||||||
.hash = "flow_syntax-0.7.2-X8jOoZAXAQBmKDyJqElxHRDqkQu5YfS54dXes-tw6zPh",
|
.hash = "flow_syntax-0.7.2-X8jOoXQZAQBvCqbqNVrI8MaCJGtp4dArhaki8igH9F3d",
|
||||||
},
|
},
|
||||||
.flags = .{
|
.flags = .{
|
||||||
.url = "git+https://github.com/neurocyte/flags?ref=main#984b27948da3e4e40a253f76c85b51ec1a9ada11",
|
.url = "git+https://github.com/neurocyte/flags?ref=main#984b27948da3e4e40a253f76c85b51ec1a9ada11",
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
pub const agda = .{};
|
pub const agda = .{};
|
||||||
|
|
||||||
|
pub const asm = .{};
|
||||||
|
|
||||||
pub const astro = .{
|
pub const astro = .{
|
||||||
.language_server = .{ "astro-ls", "--stdio" },
|
.language_server = .{ "astro-ls", "--stdio" },
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -9,11 +9,11 @@ pub fn age_short(timestamp: i64) struct {
|
||||||
else if (age < 86400)
|
else if (age < 86400)
|
||||||
writer.print("{d}h", .{@divTrunc(age, 3600)})
|
writer.print("{d}h", .{@divTrunc(age, 3600)})
|
||||||
else if (age < 2592000)
|
else if (age < 2592000)
|
||||||
writer.print("{d}d", .{@divTrunc(age, 86400)})
|
writer.print("{d}D", .{@divTrunc(age, 86400)})
|
||||||
else if (age < 31536000)
|
else if (age < 31536000)
|
||||||
writer.print("{d}mo", .{@divTrunc(age, 2592000)})
|
writer.print("{d}M", .{@divTrunc(age, 2592000)})
|
||||||
else
|
else
|
||||||
writer.print("{d}y", .{@divTrunc(age, 31536000)});
|
writer.print("{d}Y", .{@divTrunc(age, 31536000)});
|
||||||
}
|
}
|
||||||
} {
|
} {
|
||||||
return .{ .timestamp = timestamp };
|
return .{ .timestamp = timestamp };
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue