Skip to content

mitsutoshi/uni

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

uni

License: MIT

uni is a command to make unique text like uniq command.

The difference from uniq is that uni does not require sorting of the input data before running commnad.

uni can output text in the same order as when you input them.

How to use

uni receives text from stdin and unique it.

% cat text
a
c
b
c

% cat text | uni
a
c
b

How to install

If you use MacOS with Apple Silicon, you can download a binary from the Github.

https://github.com/mitsutoshi/uni/releases

Or you can get it by using Homebrew.

brew tap mitsutoshi/uni
brew install mitsutoshi/uni/uni

If you use other OS, please clone this repository to your computer and make a binary for your OS.

Note

awk can do the same thing. 😉

cat text | awk '!a[$0]++{print}'

About

uni is a command to make unique text like uniq command.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages