Add "last 6 hours" to lmcli ls categories

This commit is contained in:
Matt Low 2023-11-13 06:56:14 +00:00
parent 6af9377cf5
commit 6fde3f8932

View File

@ -61,6 +61,7 @@ var lsCmd = &cobra.Command{
categories := []string{ categories := []string{
"recent", "recent",
"last hour", "last hour",
"last 6 hours",
"last day", "last day",
"last week", "last week",
"last month", "last month",
@ -82,6 +83,8 @@ var lsCmd = &cobra.Command{
category = "recent" category = "recent"
case messageAge <= time.Hour: case messageAge <= time.Hour:
category = "last hour" category = "last hour"
case messageAge <= 6*time.Hour:
category = "last 6 hours"
case messageAge <= 24*time.Hour: case messageAge <= 24*time.Hour:
category = "last day" category = "last day"
case messageAge <= 7*24*time.Hour: case messageAge <= 7*24*time.Hour: