From a07c40d48c15b63ecea1d4c27f1b145f5143854e Mon Sep 17 00:00:00 2001 From: Christophe Kamphaus Date: Sat, 20 May 2023 23:23:33 +0200 Subject: [PATCH 1/4] Bump pkg versions in preparation of next release --- Cargo.lock | 2 +- Cargo.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 0b2d850..7323aa4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -544,7 +544,7 @@ checksum = "e5464a87b239f13a63a501f2701565754bae92d243d4bb7eb12f6d57d2269bf4" [[package]] name = "upt" -version = "1.0.0" +version = "1.0.1" dependencies = [ "chrono", "chrono-humanize", diff --git a/Cargo.toml b/Cargo.toml index f170e34..9534e61 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "upt" -version = "1.0.0" +version = "1.0.1" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html From 730d32665fb0392c39e8493ee4cc4de93e4c5a88 Mon Sep 17 00:00:00 2001 From: Christophe Kamphaus Date: Sat, 20 May 2023 23:47:32 +0200 Subject: [PATCH 2/4] Improve README --- README.md | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index bfec4bb..c386d94 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,21 @@ # upt -An alternative uptime CLI tool + +This is a simple alternative uptime CLI tool written in Rust. + +`upt` does not try to be equivalent to the `uptime` binary.
+Rather it defaults to printing duration in a human-readable format. + +Optionally the time / duration can be printed in ISO 8601 format by specifying the `--iso` flag. + +Additionally, it's possible to watch the duration by adding the `--watch` flag. + +A special feature is the ability to set the displayed uptime to zero by using the `--reset` flag. +This does not influence the system uptime counter. +This feature persists the timestamp from the moment the reset is performed. +When evaluating the start time it chooses between the system uptime and the persisted timestamp to choose the latest instant. + +All this is accomplished by relying on the fantastic Rust ecosystem and using preexisting crates as much as possible +so as not to reinvent the wheel (e.g. using `clap` for CLI argument parsing and `chrono` for time manipulation). + +Finally, a robust CI workflow is used to build release binaries for several platforms and architectures. +These release artifacts include [SBOM](https://en.wikipedia.org/wiki/Software_supply_chain) and [SLSA attestation](https://slsa.dev/). From 3fc6c7a8d059b688c5bf9805131ef9437f6f530f Mon Sep 17 00:00:00 2001 From: Christophe Kamphaus Date: Sun, 21 May 2023 00:05:49 +0200 Subject: [PATCH 3/4] Add badges to README --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index c386d94..2dcc627 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,11 @@ # upt +![GitHub](https://img.shields.io/github/license/kamphaus/upt) +![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/kamphaus/upt) +![GitHub Workflow Status (with branch)](https://img.shields.io/github/actions/workflow/status/kamphaus/upt/rust.yml?branch=main) +![Libraries.io dependency status for GitHub repo](https://img.shields.io/librariesio/github/kamphaus/upt) +![GitHub top language](https://img.shields.io/github/languages/top/kamphaus/upt) + This is a simple alternative uptime CLI tool written in Rust. `upt` does not try to be equivalent to the `uptime` binary.
From 7753de5249f97d476c7b65e78c03ce22a957b454 Mon Sep 17 00:00:00 2001 From: Christophe Kamphaus Date: Sun, 21 May 2023 00:08:52 +0200 Subject: [PATCH 4/4] Reorder badges --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2dcc627..5603f8d 100644 --- a/README.md +++ b/README.md @@ -3,8 +3,8 @@ ![GitHub](https://img.shields.io/github/license/kamphaus/upt) ![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/kamphaus/upt) ![GitHub Workflow Status (with branch)](https://img.shields.io/github/actions/workflow/status/kamphaus/upt/rust.yml?branch=main) -![Libraries.io dependency status for GitHub repo](https://img.shields.io/librariesio/github/kamphaus/upt) ![GitHub top language](https://img.shields.io/github/languages/top/kamphaus/upt) +![Libraries.io dependency status for GitHub repo](https://img.shields.io/librariesio/github/kamphaus/upt) This is a simple alternative uptime CLI tool written in Rust.