fakedate

Crates.iofakedate
lib.rsfakedate
version0.1.2-619366e
sourcesrc
created_at2021-01-02 18:03:03.384261
updated_at2021-01-03 12:58:15.445705
descriptionfakedate generates pseudo-random dates and times.
homepagehttps://gitlab.com/ufoot/fakedate
repositoryhttps://gitlab.com/ufoot/fakedate/tree/master
max_upload_size
id330674
size59,713
Christian Mauduit (ufoot)

documentation

https://docs.rs/crate/fakedate/0.0.1

README

Fakedate

Fakedate generates pseudo-random dates and times.

It is written in Rust and is mostly a toy project to ramp up on the language. It might however be useful. Use at your own risk.

Fakedate icon

Status

Build Status

Current version is 0.1.2.

Install

No install target yet, copy the fakedate binary in your $PATH if you wish, that's all.

A few commands which may prove useful:

cargo build             # build debug binary in ./target/debug/
cargo build --release   # build release binary in ./target/release/
cargo test              # launch tests
rustfmt src/*.rs        # format code
./docker-build.sh       # build Docker image with version tag
./bump-version.sh       # bump minor version number

Usage

Simply launch:

cargo run

Or just run the binary directly:

./target/debug/fakedate
./target/release/fakedate

Alternatively, using docker:

docker run ufoot/fakedate

To pass options:

cargo run -- -1975

By default, the date is a random date for the current year. To use a different year:

fakedate -1975

Other standard options include:

  • -n, --no-newline: no newline char at the end of the date
  • -w, --week-end: force the date to be last week-end
  • -h, --help: display a short help.
  • -v, --version: display version.

Legal information

Fakedate is licensed under the MIT license.

Commit count: 0

cargo fmt