Skip to content

Commit

Permalink
docs(README): add Tokei example
Browse files Browse the repository at this point in the history
  • Loading branch information
tomcur committed Jun 29, 2024
1 parent 4850b72 commit 1259a74
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@ $ (

![Termsnap output of some tty commands](./media/tty.svg)

```bash
$ termsnap -o ./media/tokei.svg -l 22 -c 80 -- tokei
```

![Termsnap output of the Tokei lines of code counter](./media/tokei.svg)

## Installation

Install using Cargo:
Expand Down
3 changes: 3 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@
rustc
rustfmt
bashInteractive

# Programs for Termsnap examples
cowsay
tokei
];
};
}
Expand Down
32 changes: 32 additions & 0 deletions media/tokei.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions scripts/examples.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ export PATH="$PWD/target/release":$PATH

termsnap -o ./media/cow.svg -l 9 -c 28 -- cowsay Hello, world

termsnap -o ./media/tokei.svg -l 22 -c 80 -- tokei

(
# `sleep` gives bash time to be ready for the command, if this is omitted
Expand Down

0 comments on commit 1259a74

Please sign in to comment.