Drop-in replacement and standalone version of the hex dump utility that comes with ViM
OTHER License
Bot releases are hidden (Show)
tinyxxd
under both GPL-2.0-only
and MIT
(closes #7, thanks @philiptaron, @emilazy, @Ordoviz and @oliverkwebb)Published by xyproto about 2 months ago
AUTHORS.md
(ref #7, thanks @philiptaron and @emilazy).README.md
(ref #8, thanks @philiptaron).Published by xyproto 5 months ago
-a
), 2204d75eede6ff3b9628202780dbde6f04054a33 (thanks @Ordoviz)-a -E -R always
behaving incorrectly 27df9896ae95cc8200e80a70cfb5cbacb3d2a577 (thanks @Ordoviz)EXIT_FAILURE
instead of 1
.Published by xyproto 6 months ago
#define
.LLEN
only once.#define
by replacing it with an enum
.COLS
enum instead of passing it in as an argument to several functions.(void)
to a function signature so that the program also compiles on macOS.Published by xyproto 8 months ago
static inline
.CFLAGS
in the Makefile
.README.md
.Published by xyproto 8 months ago
hextype
in multiple locations. Check it once in main
and then call the right function.inline
.const
for several of the function arguments and variables.kcachegrind
.NULL
and 0
. (thanks @oliverkwebb).(void)
arguments (thanks @oliverkwebb).snprintf
(thanks @oliverkwebb).fflush_or_die
and a fflush_fseek_and_putc
function.enum
for the terminal colors.setColor
and clearColor
instead of colorPrologue
and colorEpilogue
.ignore
variable be a bool
instead of an int
.profile
target to the Makefile
.bench.py
that confirms that the performance is mostly IO-bound, and also outputs a couple of graphs by using gnuplot
.main
branch.release.sh
script into the Makefile
, and remove the script.make fuzz
, by using afl-gcc
and afl-fuzz
.Published by xyproto 9 months ago
main.c
switch
instead of if
/else
in get_ascii_char
and get_ebcdic_char
.pname
to program_name
, fpi
to input_file
and fpo
to output_file
.output_file
be global, and use char literals instead of numbers (ref #2, thanks @oliverkwebb).input_file
be global.COL
and LLEN
be defines instead of constexpr
, to support versions of C before C23.boolean
s instead of int
s, whenever possible.perror_exit
function, but let the error_exit
have the same functionality if no message is passed in.lower_hex_digits
and upper_hex_digits
separately, rather than having an index number change to indicate lower or upper digits.fprintf
once when the --help
flag is passed in, instead of once per line of output.conditionalCapitalize
function, and move the check for if hex digits should be capitalized outside of the for
-loops where it is used.uppercase_hex
boolean, for if the -u
flag is passed in, and move the check outside of the loops where it is used.Makefile
fmt
target to the Makefile that calls clang-format
and formats the source code.-finline-functions
to the default flags, and remove the inline
keyword from all function declarations.make clean
also remove *.o
.clang-format
and the WebKit
style.Published by xyproto 9 months ago
Published by xyproto 9 months ago
xxd
utility that comes with ViM.