Sync with -current ls to make the field width agree for long listings with

human-readable sizes.
This commit is contained in:
naddy 2004-05-28 22:03:49 +00:00
parent 745a04ca39
commit b4d0317fd6
3 changed files with 15 additions and 15 deletions

View File

@ -1,8 +1,8 @@
# $OpenBSD: Makefile,v 1.6 2004/02/25 22:25:11 naddy Exp $
# $OpenBSD: Makefile,v 1.7 2004/05/28 22:03:49 naddy Exp $
COMMENT= "ls that can use color to display file attributes"
DISTNAME= ls-3.5
DISTNAME= ls-3.5.1
PKGNAME= color${DISTNAME}
CATEGORIES= sysutils

View File

@ -1,3 +1,3 @@
MD5 (ls-3.5.tar.gz) = ee6e44eebeb6e781b5f323f4d63e9ae3
RMD160 (ls-3.5.tar.gz) = e297815ef61dd18731b92ad0dab9114355d4006a
SHA1 (ls-3.5.tar.gz) = faad97f7ba851dd57f23060bd95d600863e3cec6
MD5 (ls-3.5.1.tar.gz) = 7cdbda3bd165b9856f8800a488883042
RMD160 (ls-3.5.1.tar.gz) = 866047e5570c68fa5dec9b6011adeb9f23720a28
SHA1 (ls-3.5.1.tar.gz) = b94ff6e376828a701a86449b2f468ff1f43b6a96

View File

@ -1,10 +1,10 @@
$OpenBSD: patch-ls_c,v 1.4 2003/08/27 00:41:51 naddy Exp $
--- ls.c.orig 2003-08-27 00:37:00.000000000 +0200
+++ ls.c 2003-08-27 00:47:19.000000000 +0200
@@ -61,6 +61,10 @@ static char rcsid[] = "$OpenBSD: ls.c,v
#include <stdlib.h>
$OpenBSD: patch-ls_c,v 1.5 2004/05/28 22:03:49 naddy Exp $
--- ls.c.orig 2004-05-28 23:50:09.000000000 +0200
+++ ls.c 2004-05-28 23:54:03.000000000 +0200
@@ -62,6 +62,10 @@ static char rcsid[] = "$OpenBSD: ls.c,v
#include <string.h>
#include <unistd.h>
#include <util.h>
+#ifdef COLORLS
+#include <termcap.h>
+#include <signal.h>
@ -12,7 +12,7 @@ $OpenBSD: patch-ls_c,v 1.4 2003/08/27 00:41:51 naddy Exp $
#include "ls.h"
#include "extern.h"
@@ -105,6 +109,15 @@ int f_dirname; /* if precede with dire
@@ -106,6 +110,15 @@ int f_dirname; /* if precede with dire
int f_type; /* add type character for non-regular files */
int f_typedir; /* add type character for directories */
int f_whiteout; /* show whiteout entries */
@ -28,7 +28,7 @@ $OpenBSD: patch-ls_c,v 1.4 2003/08/27 00:41:51 naddy Exp $
int rval;
@@ -116,6 +129,11 @@ ls_main(int argc, char *argv[])
@@ -117,6 +130,11 @@ ls_main(int argc, char *argv[])
int ch, fts_options, notused;
int kflag = 0;
char *p;
@ -40,7 +40,7 @@ $OpenBSD: patch-ls_c,v 1.4 2003/08/27 00:41:51 naddy Exp $
/* Terminal defaults to -Cq, non-terminal defaults to -1. */
if (isatty(STDOUT_FILENO)) {
@@ -133,7 +151,7 @@ ls_main(int argc, char *argv[])
@@ -134,7 +152,7 @@ ls_main(int argc, char *argv[])
f_listdot = 1;
fts_options = FTS_PHYSICAL;
@ -49,7 +49,7 @@ $OpenBSD: patch-ls_c,v 1.4 2003/08/27 00:41:51 naddy Exp $
switch (ch) {
/*
* The -1, -C and -l, -m and -x options all override each
@@ -178,6 +196,9 @@ ls_main(int argc, char *argv[])
@@ -179,6 +197,9 @@ ls_main(int argc, char *argv[])
case 'F':
f_type = 1;
break;
@ -59,7 +59,7 @@ $OpenBSD: patch-ls_c,v 1.4 2003/08/27 00:41:51 naddy Exp $
case 'L':
fts_options &= ~FTS_PHYSICAL;
fts_options |= FTS_LOGICAL;
@@ -245,11 +266,46 @@ ls_main(int argc, char *argv[])
@@ -246,11 +267,46 @@ ls_main(int argc, char *argv[])
argc -= optind;
argv += optind;