summaryrefslogtreecommitdiff
path: root/src/ls.c
AgeCommit message (Collapse)Author
1997-01-15[!STDC_HEADERS]: Remove unnecessary declaration of free.Jim Meyering
1997-01-09(print_long_format): Cast alloca return value to char*.Jim Meyering
1997-01-05(print_long_format): Detect and handle strftime failureJim Meyering
due to pathologically long strings in locale tables. Patch from Paul Eggert. (print_long_format): Change references to BIGBUF in use of FPUT macro to references to BUF. Use 11 (not 20) bytes for mode string buffer.
1997-01-05(print_long_format): NUL-terminate line of output.Jim Meyering
1997-01-05(print_long_format): First patch from Paul Eggert.Jim Meyering
1997-01-05(print_long_format): Clean up vestiges of legacyJim Meyering
ctime-oriented code. With internationalization and strftime, you can't presume that %a expands to a 3-byte string. Reported by Ross Ridge.
1996-12-29Two problems fixed by these changes from Joakim Rosqvist.Jim Meyering
Quoting Joakim: 1) The "total" number and the size of the first file as output from 'ls --color -s' did not get colorized according to the "no"-argument in LS_COLORS. Fixed by adding a function prep_non_filename_text which prints the C_LEFT C_NORM C_RIGHT strings (or C_END). It is called from main before any text is output, and from print_name_with_quoting after having output a colorized filename. 2) If the "no"-argument of LS_COLORS is set, the terminal will be set to print in that color after ls exits. The man-pages suggests setting "no" and "fi" to the terminals default colors to avoid the problem, but that would mean I can't use anything but the default color for regular files and non-filename text. Fixed by outputting C_LEFT immediately followed by C_RIGHT right before exit, which restores the default color.
1996-12-28Correct obsolete comment referring to macro that is now ls_mode.Jim Meyering
1996-12-19(gobble_file): Stat symlinks also when printing withJim Meyering
color and set linkok to reflect existence of referent. Patches from Joakim Rosqvist, James Antill, and Jesse Thilo.
1996-12-04(print_color_indicator): Initialize EXT to NULL.Jim Meyering
1996-12-03(print_color_indicator): Check the file's suffix onlyJim Meyering
if it's a regular file. (print_type_indicator): Use S_IXUGO instead of writing out (S_IEXEC | S_IXGRP | S_IXOTH). (length_of_file_name_and_frills): Likewise.
1996-11-30(main): Close stdout and check result, in case any deferred writes fail.Jim Meyering
Use EXIT_SUCCESS and EXIT_FAILURE in exit and usage calls.
1996-11-23(usage): Alphabetize option descriptions the way sort -f would.Jim Meyering
1996-11-03change bug-reporting addressJim Meyering
1996-11-02change bug-reporting addressJim Meyering
1996-11-02(gobble_file): Set linkok for non-orphaned symlinks.Jim Meyering
From Bauke Jan Douma. (gobble_file): Initialize linkok. With these two changes, ls --color should display orphaned symlinks as blinking text on terminals that support it.
1996-10-29(decode_switches): Make -A set really_all_files to zeroJim Meyering
as well as setting all_files to 1. With this change, ls -f -A prints everything but . and .., unsorted. Before, the -A was effectively ignored. From Karl Berry.
1996-10-13(print_long_format): Use strftime of localtimeJim Meyering
(not ctime) to produce the date/time in long listings. From Rafal Maszkowski.
1996-10-09(usage): Improve brief descriptions of --sort and --time.Jim Meyering
From François Pinard.
1996-10-08(usage): Improve usage messagesJim Meyering
1996-10-05(print_long_format): Add support for Cray's migrated dmf files.Jim Meyering
From Johan Danielsson.
1996-10-05(main): update --version output to conform to coding standardJim Meyering
1996-08-31(usage): remove spurious trailing \n in puts.Jim Meyering
1996-08-29(usage): Tell where to report bugs.Jim Meyering
1996-07-08Make initial colors for `color_indicator' match thoseJim Meyering
currently in dircolors.hin.
1996-07-08Include termios.h.Jim Meyering
Guard inclusion of sys/ioctl.h with #ifdef GWINSZ_IN_SYS_IOCTL, rather than HAVE_SYS_IOCTL_H. Modelled after sh-utils' stty.c at suggestion from Chip Bennett <BennettC@j64.stratcom.af.mil>.
1996-07-04(main): Fix typo in last change.Jim Meyering
1996-07-04Make `dir --version' and `vdir --version' print their names, not `ls'.Jim Meyering
Reported by Ulrich Drepper.
1996-07-03(usage): Add omitted \n\ at the end of a line in the usage message.Jim Meyering
1996-06-29Remove u from Colour.Jim Meyering
1996-06-25(decode_switches): Allow 0 as argument to --tabsize (-T) option.Jim Meyering
Interpret as a directive to use no TAB characters to separate columns. (indent): Handle TABSIZE == 0.
1996-06-19(parse_ls_color): Use STREQ here instead of strcmp(...) == 0.Jim Meyering
1996-06-19(decode_switches): Correct typo in error message: enironment -> environment.Jim Meyering
From Santiago Vila Doncel <sanvila@unex.es>.
1996-06-02Declare pointer parameters const as appropriate.Jim Meyering
1996-06-01(decode_switches): Set print_with_color in one statement.Jim Meyering
1996-06-01Rename options and internal variables to reflect change toJim Meyering
--color=WHEN where WHEN is never, always, or auto (for consistency with e.g. cp --sparse=WHEN. For at least a while, the original slackware-supported arguments `none', `force', `yes', etc will be supported but deprecated by lack of documentation. (decode_switches): Use STDOUT_FILENO instead of `1' in is_tty test. (usage): Update/add description of the --color option.
1996-05-23(usage): Make --literal (-N) description clearer.Jim Meyering
1996-05-02.Jim Meyering
1996-05-02(parse_ls_color, usage): Remove support for alternate spellings:Jim Meyering
--colours and LS_COLOURS. (parse_ls_color): Reverse sense of test for LS_COLORS environment variable and return -- save a level of indentation on a 100+-line block.
1996-05-01(parse_ls_color, usage): Remove support for alternate spellings:Jim Meyering
--colours and LS_COLOURS.
1996-04-29(print_name_with_quoting): Add braces around inner if-else stmt.Jim Meyering
1996-04-29(LEN_STR_PAIR): New macro.Jim Meyering
(color_indicator): Use it in this declaration. (parse_ls_color): Use error, not fprintf. (decode_switches): Add a comment.
1996-04-29(parse_ls_color): Use strcpy to initialize 3-character array.Jim Meyering
Automatic aggregate initialization isn't portable.
1996-04-29Remove all ^L's.Jim Meyering
(get_funky_string): Declare static and move to precede single caller: parse_ls_color.
1996-04-29(get_funky_string): Upper-case anon. union `state'.Jim Meyering
1996-04-29Apply color ls changes from Drepper.Jim Meyering
1996-04-27Fri Apr 26 05:52:03 1996 Karl Eichwalder <ke@ke.Central.DE>Jim Meyering
* ls.c (usage): Add newline at end of printf format string.
1996-04-24update Copyright years for 1996Jim Meyering
1996-04-21(decode_switches): Replace two more atoi uses with xstrtol.Jim Meyering
1996-04-21(decode_switches): Use getenv (POSIXLY_CORRECT), not undefined posix_pedantic.Jim Meyering