aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2013-08-03Print diagnostic for wrong count of argumentsGravatar Steven Schubiger 1-0/+1
2013-08-03Quote original unrecognized color nameGravatar Steven Schubiger 1-6/+11
This fixes the name being quoted for bold colors: [sts@kronos colorize-eaf4e19]$ ./colorize Greeen ./colorize: foreground color 'greeen' not recognized
2013-07-31Add vfprintf_diag and macroGravatar Steven Schubiger 1-6/+16
2013-07-30Revert "Make vfprintf_{fail,diag} wrappers"Gravatar Steven Schubiger 1-7/+3
This reverts commit fbbedc1d43af9c4fbc92611db19c617378dce2e8. Undo as variadic macros are not allowed in C89.
2013-07-27Make vfprintf_{fail,diag} wrappersGravatar Steven Schubiger 1-3/+7
2013-07-16Check for non-empty lineGravatar Steven Schubiger 1-1/+1
2013-07-13Eliminate stream modesGravatar Steven Schubiger 1-66/+13
The added complexity is not worth the cost as these modes do not provide a real speed benefit nor is the implementation mature. Thus, remove them.
2013-07-04Tighten scope of testGravatar Steven Schubiger 1-4/+6
2013-07-03Clean sequences more strictlyGravatar Steven Schubiger 2-17/+49
2013-06-16Mention that sequences are added on a line basisGravatar Steven Schubiger 1-1/+4
2013-05-28Bail out if both clean switches are providedGravatar Steven Schubiger 1-0/+2
2013-05-18Allow for DEBUG to be overriddenGravatar Steven Schubiger 1-1/+3
2013-05-13Add note in line printing functionGravatar Steven Schubiger 1-0/+1
2013-05-07Double space at end of sentenceGravatar Steven Schubiger 1-3/+3
2013-04-29First draft of man pageGravatar Steven Schubiger 1-0/+43
2013-04-26Introduce calloc wrappers and zero memoryGravatar Steven Schubiger 1-5/+27
Zero allocated memory of size "color name" struct to allow for free() to be called for struct members even when not all of them have been set explicitly yet. This is necessary since freeing those might take place prematurely in cleanup() (triggered via atexit).
2013-04-24colorize 0.50v0.50Gravatar Steven Schubiger 1-1/+1
2013-04-24Test clean-all featureGravatar Steven Schubiger 1-9/+27
2013-04-09Clean text from all color escape sequencesGravatar Steven Schubiger 1-42/+65
2013-03-05Reduce short options codeGravatar Steven Schubiger 1-6/+7
2013-03-04Optimize parsing command-line optionsGravatar Steven Schubiger 1-22/+45
2013-03-03Test count of sequences being printedGravatar Steven Schubiger 1-1/+6
2013-03-03Don't print pair of sequences at end-of-fileGravatar Steven Schubiger 1-11/+13
2013-02-24Add blank lineGravatar Steven Schubiger 1-0/+1
2013-02-19Print actual color separator in help outputGravatar Steven Schubiger 1-1/+1
2013-02-19Define color separator onceGravatar Steven Schubiger 1-4/+6
2013-02-18Adjust format specifier for unsigned integersGravatar Steven Schubiger 1-4/+4
2013-02-17colorize 0.49v0.49Gravatar Steven Schubiger 1-1/+1
2013-02-17Use size_t instead of unsigned integer typeGravatar Steven Schubiger 1-2/+2
2013-02-15Enclose valgrind test in skip blockGravatar Steven Schubiger 1-2/+4
2013-02-15Narrow scope of variablesGravatar Steven Schubiger 1-8/+6
2013-02-11Advance position for end sequenceGravatar Steven Schubiger 1-1/+2
2013-02-10Keep makefile simpleGravatar Steven Schubiger 1-6/+3
2013-02-09Improve wrapping memory functionsGravatar Steven Schubiger 3-22/+43
2013-02-09Test clean featureGravatar Steven Schubiger 1-8/+31
2013-02-08Skip invalid sequences correctlyGravatar Steven Schubiger 1-1/+2
2013-02-07Clean text from color escape sequencesGravatar Steven Schubiger 1-29/+213
In order to handle end-of-buffer reads with partial line chunks, merge those when cleaning text. Pass each line then to the offset extracting function which gathers begin/end offsets of escape sequences. Finally, for printing cleaned lines of text, omit all color escape sequences as defined by their set of offsets (and restore characters temporarily overwritten with terminating NUL). Furthermore, add a basic string concatenation function and wrap the free memory function to have it nullify pointers.
2013-01-28Enhance message if color string exists as fileGravatar Steven Schubiger 1-1/+6
2013-01-25Capitalize first letter of diagnosticsGravatar Steven Schubiger 1-2/+2
2013-01-25update copyright year and increase versionGravatar Steven Schubiger 1-2/+2
2013-01-25add -Wno-unused-parameterGravatar Steven Schubiger 2-2/+2
2013-01-24Wrap memory allocation functionsGravatar Steven Schubiger 1-6/+45
This covers currently calls to malloc(), realloc() and the custom strdup() (which uses malloc, too). If allocation of memory fails (i.e., NULL is returned from one of former two calls), a fatal diagnostic is emitted (accompanied by source filename and line number if compiled with DEBUG=1).
2012-12-18Initial commit.Gravatar Steven Schubiger 3-0/+841