Skip to content
/ Coin Public

A light hex/decimal/binary value converter and file hexdump straight to your shell.

Notifications You must be signed in to change notification settings

VtotheK/Coin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Coin

A lightweight program for UNIX systems for converting single or multiple hex/decimal/binary values at once. Includes a few optional flags for desired output.

Also inludes a file hexdump, straight to your terminal.

Prerequisites

You need makefile to compile the program

sudo apt install make

and C compiler

sudo apt install gcc

After installing these packets, type command make in the directory where this program is.

After compiling the program

Write the following command to see the list of available commands

./coin --h

Examples

Let's convert some hexadecimal values into decimal and binary values

vtothek@ubuntu ~ $ coin -hd 9F
159 

You can also chain values to get multiple conversions

vtothek@ubuntu ~ $ coin -hd 9F 800A FFA
159 32778 4090

Binary conversion

vtothek@ubuntu ~ $ coin -hb 9F 800A FFA
10011111 1000000000001010 111111111010 

Invalid input example

vtothek@ubuntu ~ $ coin -hb 9F 800A FFA 9G
10011111 1000000000001010 111111111010 Invalid input 

Optional flags

You can also print the input values, use custom delimiter and print values vertically

Original input values with --ov flag

vtothek@ubuntu ~ $ coin -hd 9F 800A FFA 9G --ov
9F=159 800A=32778 FFA=4090 9G=Invalid input 

Custom input/output delimiter with --cd flag

vtothek@ubuntu ~ $ coin -hd 9F 800A FFA 9G --ov --cd::
9F::159 800A::32778 FFA::4090 9G::Invalid input

Vertical output with --v flag

vtothek@ubuntu ~ $ coin -hd 9F 800A FFA 9G --ov --cd:: --v
9F::159 
800A::32778 
FFA::4090 
9G::Invalid input

File hexdump

You can print colored file hexdump into console with -f flag.

Coin hexdump

You can also limit the amout of outputted bytes with --l flag.

Coin hexdump bytes limited

Youtube demo

https://www.youtube.com/watch?v=-IPx8CzpF5A&

About

A light hex/decimal/binary value converter and file hexdump straight to your shell.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published