Re: ls sort order: new, bad, behaviour

2007-09-27 Thread Michelle Konzack
Am 2007-09-24 02:44:13, schrieb Eric d'Alibut:
 On 9/24/07, Ron Johnson [EMAIL PROTECTED] wrote:
 
  Jeez, this has been a bad computer day for me.
 
  ls listings are just like Steve's.
 
 I'm back to my figment of the imagination idea: this phantom
 dirs-first ls listing is a delusion produced by too much mc use.
- END OF REPLIED MESSAGE -

Maybe you should write a wraper for ls which do it?

Thanks, Greetings and nice Day
Michelle Konzack
Systemadministrator
Tamay Dogan Network
Debian GNU/Linux Consultant


-- 
Linux-User #280138 with the Linux Counter, http://counter.li.org/
# Debian GNU/Linux Consultant #
Michelle Konzack   Apt. 917  ICQ #328449886
   50, rue de Soultz MSN LinuxMichi
0033/6/6192519367100 Strasbourg/France   IRC #Debian (irc.icq.com)


signature.pgp
Description: Digital signature


Re: ls sort order: new, bad, behaviour

2007-09-23 Thread Ron Johnson
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 09/23/07 00:49, Eric d'Alibut wrote:
 On 9/22/07, Benjamin A'Lee [EMAIL PROTECTED] wrote:
 
 Do 'printenv | grep LC_COLLATE' or 'locale' show the right setting?
 
 I am beginning to think I am a victim of my addled pate. Have I been
 using midnight commander too much? Am I looking for a fig newton of my
 imagination, namely, an 'ls' that sorts directories first, and
 ordinary files afterwards? Do others actually see that behaviour in
 terminals?

Sure.  That's how it works for me.

$ locale
LANG=
LANGUAGE=en_US:en_GB:en
LC_CTYPE=POSIX
LC_NUMERIC=POSIX
LC_TIME=POSIX
LC_COLLATE=POSIX
LC_MONETARY=POSIX
LC_MESSAGES=POSIX
LC_PAPER=POSIX
LC_NAME=POSIX
LC_ADDRESS=POSIX
LC_TELEPHONE=POSIX
LC_MEASUREMENT=POSIX
LC_IDENTIFICATION=POSIX
LC_ALL=



- --
Ron Johnson, Jr.
Jefferson LA  USA

Give a man a fish, and he eats for a day.
Hit him with a fish, and he goes away for good!

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFG9l5rS9HxQb37XmcRAknrAKDT6Up+kz2YEx45dX1+aD2fA4rVCwCdGIJ8
34i3wHfjh73CH3cGJyXrYAY=
=+OBb
-END PGP SIGNATURE-


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: ls sort order: new, bad, behaviour

2007-09-23 Thread Eric d'Alibut
On 9/23/07, Ron Johnson [EMAIL PROTECTED] wrote:

  namely, an 'ls' that sorts directories first, and
  ordinary files afterwards? Do others actually see that behaviour in
  terminals?

 Sure.  That's how it works for me.

 $ locale
 LANG=
 LANGUAGE=en_US:en_GB:en
 LC_CTYPE=POSIX
 LC_NUMERIC=POSIX
 LC_TIME=POSIX
 LC_COLLATE=POSIX
 LC_MONETARY=POSIX
 LC_MESSAGES=POSIX
 LC_PAPER=POSIX
 LC_NAME=POSIX
 LC_ADDRESS=POSIX
 LC_TELEPHONE=POSIX
 LC_MEASUREMENT=POSIX
 LC_IDENTIFICATION=POSIX
 LC_ALL=

I have those values in place, partly as a result of doing 'export
LANGUAGE=en_US:en_GB:en', and I now have 'locale' output identical to
yours, but not the wanted 'dirs-first' behaviouir:

[EMAIL PROTECTED]:~$ locale
LANG=
LANGUAGE=en_US:en_GB:en
LC_CTYPE=POSIX
LC_NUMERIC=POSIX
LC_TIME=POSIX
LC_COLLATE=POSIX
LC_MONETARY=POSIX
LC_MESSAGES=POSIX
LC_PAPER=POSIX
LC_NAME=POSIX
LC_ADDRESS=POSIX
LC_TELEPHONE=POSIX
LC_MEASUREMENT=POSIX
LC_IDENTIFICATION=POSIX
LC_ALL=

$ ~$ ls -l |more
total 255108
-rw-r--r--  1 zoidberg zoidberg  1702 Oct 17  2005 BobZoidmanBernstein.asc
-rw-r--r--  1 zoidberg zoidberg  1053 Mar 14  2006 DisDetFunc.aux
-rw-r--r--  1 zoidberg zoidberg  8456 Mar 14  2006 DisDetFunc.log
-rw-r--r--  1 zoidberg zoidberg   258 Mar 14  2006 DisDetFunc.out
-rw-r--r--  1 zoidberg zoidberg 70809 Mar 14  2006 DisDetFunc.pdf
-rw-r--r--  1 zoidberg zoidberg 17626 Mar 14  2006 DisDetFunc.sgml
-rw-r--r--  1 zoidberg zoidberg 17609 Mar 14  2006 DisDetFunc.sgml~
-rw-r--r--  1 zoidberg zoidberg 16340 Mar 14  2006 DisDetFunc.tex
-rw-r--r--  1 zoidberg zoidberg204241 May  3  2006 HeideggerSpiegel.pdf
-rw---  1 zoidberg zoidberg   157 Jun 12 23:48 KathyAmex.txt.nc
-rw---  1 zoidberg zoidberg  1258 Nov  5  2006 Mailbox
drwx-- 12 zoidberg zoidberg  1024 Jul 19 16:20 Maildir
-rw-r--r--  1 root root   645 Nov  9  2006 Muttrc
-rw-r--r--  1 zoidberg zoidberg744180 Feb 10  2006 Silva-1.4-extra-2.tgz
-rw-r--r--  1 zoidberg zoidberg   5416881 Feb 10  2006 Silva-1.4.1-all.tgz
.gz
-rw---  1 root root   157 Sep 16  2006 alison.txt.nc

Do you have LS_OPTIONS set, or 'ls' aliased?

If I may make so bold as to speak for others too, I hate this locale
stuff that has descended on us since etch came into the world. Is
there a nice dummy-friendly Debian Locale How-To? How, for instance,
did you *set* those locale values shown in your post?

Go Sox.

Best regards,

-- 
No no no, my fish's name is Eric, Eric the fish. He's an halibut. I am
not a looney! Why should I be tarred with the epithet looney merely
because I have a pet halibut?


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: ls sort order: new, bad, behaviour

2007-09-23 Thread Mumia W..

On 09/23/2007 03:05 PM, Eric d'Alibut wrote:

[...]
Do you have LS_OPTIONS set, or 'ls' aliased?



I apologize for suggesting that aliasing ls to 'ls -X' would give the 
behavior you want; it does not (but it comes close).


I've never seen ls sort directory names first.


If I may make so bold as to speak for others too, I hate this locale
stuff that has descended on us since etch came into the world. Is
there a nice dummy-friendly Debian Locale How-To? How, for instance,
did you *set* those locale values shown in your post?

Go Sox.

Best regards,



Man 5 locale isn't dummy-friendly, but it describes LC_COLLATE.

You can set the default locale by issuing (as root):

dpkg-reconfigure locales

However, changing the locale won't get ls to sort directories first. As 
you realized earlier, that is a feature of Midnight Commander (mc).




--
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]




Re: ls sort order: new, bad, behaviour

2007-09-23 Thread s. keeling
Eric d'Alibut [EMAIL PROTECTED]:
  On 9/23/07, Ron Johnson [EMAIL PROTECTED] wrote:
 
   namely, an 'ls' that sorts directories first, and
   ordinary files afterwards? Do others actually see that behaviour in
   terminals?
 
  Sure.  That's how it works for me.

Not for me.  I get all dotfiles and dotdirs alphabetically, followed
by non-dotdirs.  It's .(A-Z then a-z):

-rw---  1 keeling keeling   199 2007-07-12 14:30 .Xauthority
-rwxr-xr-x  1 keeling keeling   643 2007-09-05 20:36 .Xclients*
-rw-r--r--  1 keeling keeling28 2007-06-10 06:53 .Xmodmap
-rw-r--r--  1 keeling keeling 11475 2007-09-15 12:59 .Xresources
-rw-r--r--  1 keeling keeling  1045 2007-09-23 10:54 .abcde.conf
-rw-r--r--  1 keeling keeling  3943 2007-09-10 20:16 .alias
drwx--  2 keeling keeling  4096 2007-09-23 10:54 .aptitude/
-rw---  1 keeling keeling 10032 2007-09-23 14:34 .bash_history
-rw-r--r--  1 keeling keeling   158 2007-06-10 11:01 .bash_logout
-rw-r--r--  1 keeling keeling  1158 2007-06-14 12:44 .bashrc
drwx--  2 keeling keeling  4096 2007-09-01 00:15 .bogofilter/
-rw---  1 keeling keeling   210 2007-06-23 08:36 .cvspass
drwx--  3 keeling keeling  4096 2007-08-05 16:14 .dbus/
-rw-r--r--  1 keeling keeling  9919 2007-07-10 16:47 .emacs
...
-rw-r--r--  1 keeling keeling 11624 2007-06-23 15:00 .xscreensaver
-rw---  1 keeling keeling 0 2007-06-23 18:37 .xsession-errors
drwxr-x---  3 keeling keeling  4096 2007-09-23 14:54 Mail/
drwxr-xr-x  5 keeling keeling  4096 2007-09-23 15:01 News/
drwxr-xr-x  2 keeling keeling  4096 2007-08-07 09:30 Xprintjobs/
...
drwxr-xr-x  2 keeling keeling  4096 2007-09-15 09:45 sh/
drwxr-xr-x  2 keeling keeling  4096 2007-06-10 07:13 snd/
drwxr-xr-x  4 keeling keeling  4096 2007-09-23 10:54 tmp/
drwxr-xr-x  2 keeling keeling  4096 2007-09-02 07:55 winfonts/


  $ locale
  LANG=
  LANGUAGE=en_US:en_GB:en
 
  I have those values in place, partly as a result of doing 'export
  LANGUAGE=en_US:en_GB:en', and I now have 'locale' output identical to
  yours, but not the wanted 'dirs-first' behaviouir:

Nor do I.

(0) heretic /home/keeling_ echo $LC_COLLATE
C

 
  If I may make so bold as to speak for others too, I hate this locale
  stuff that has descended on us since etch came into the world. Is
  there a nice dummy-friendly Debian Locale How-To? How, for instance,
  did you *set* those locale values shown in your post?

Well, there's dpkg-reconfigure locales.  Then you just choose to use
them.  Most take their cue from what locale says, while some apps can
be extended, ie. mutt uses magic like:

set send_charset=us-ascii:iso-8859-1:iso-8859-15:utf-8


-- 
Any technology distinguishable from magic is insufficiently advanced.
(*)http://blinkynet.net/comp/uip5.html  Linux Counter #80292
- -http://www.faqs.org/rfcs/rfc1855.htmlPlease, don't Cc: me.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: ls sort order: new, bad, behaviour

2007-09-23 Thread Ron Johnson
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 09/23/07 16:11, s. keeling wrote:
 Eric d'Alibut [EMAIL PROTECTED]:
  On 9/23/07, Ron Johnson [EMAIL PROTECTED] wrote:

 namely, an 'ls' that sorts directories first, and
 ordinary files afterwards? Do others actually see that behaviour in
 terminals?
 Sure.  That's how it works for me.
 
 Not for me.  I get all dotfiles and dotdirs alphabetically, followed
 by non-dotdirs.  It's .(A-Z then a-z):
 
 -rw---  1 keeling keeling   199 2007-07-12 14:30 .Xauthority
 -rwxr-xr-x  1 keeling keeling   643 2007-09-05 20:36 .Xclients*
 -rw-r--r--  1 keeling keeling28 2007-06-10 06:53 .Xmodmap
 -rw-r--r--  1 keeling keeling 11475 2007-09-15 12:59 .Xresources
 -rw-r--r--  1 keeling keeling  1045 2007-09-23 10:54 .abcde.conf
 -rw-r--r--  1 keeling keeling  3943 2007-09-10 20:16 .alias
 drwx--  2 keeling keeling  4096 2007-09-23 10:54 .aptitude/
 -rw---  1 keeling keeling 10032 2007-09-23 14:34 .bash_history
 -rw-r--r--  1 keeling keeling   158 2007-06-10 11:01 .bash_logout
 -rw-r--r--  1 keeling keeling  1158 2007-06-14 12:44 .bashrc
 drwx--  2 keeling keeling  4096 2007-09-01 00:15 .bogofilter/
 -rw---  1 keeling keeling   210 2007-06-23 08:36 .cvspass
 drwx--  3 keeling keeling  4096 2007-08-05 16:14 .dbus/
 -rw-r--r--  1 keeling keeling  9919 2007-07-10 16:47 .emacs
 ...
 -rw-r--r--  1 keeling keeling 11624 2007-06-23 15:00 .xscreensaver
 -rw---  1 keeling keeling 0 2007-06-23 18:37 .xsession-errors
 drwxr-x---  3 keeling keeling  4096 2007-09-23 14:54 Mail/
 drwxr-xr-x  5 keeling keeling  4096 2007-09-23 15:01 News/
 drwxr-xr-x  2 keeling keeling  4096 2007-08-07 09:30 Xprintjobs/
 ...
 drwxr-xr-x  2 keeling keeling  4096 2007-09-15 09:45 sh/
 drwxr-xr-x  2 keeling keeling  4096 2007-06-10 07:13 snd/
 drwxr-xr-x  4 keeling keeling  4096 2007-09-23 10:54 tmp/
 drwxr-xr-x  2 keeling keeling  4096 2007-09-02 07:55 winfonts/

Jeez, this has been a bad computer day for me.

ls listings are just like Steve's.

- --
Ron Johnson, Jr.
Jefferson LA  USA

Give a man a fish, and he eats for a day.
Hit him with a fish, and he goes away for good!

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFG9xP8S9HxQb37XmcRAihGAJ9w/3frP7HEzgJkam9YoKGfWDYKOgCgmbDF
NRW877wo2CCxmoZbCdwFXoY=
=0ORE
-END PGP SIGNATURE-


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: ls sort order: new, bad, behaviour

2007-09-23 Thread Eric d'Alibut
On 9/24/07, Ron Johnson [EMAIL PROTECTED] wrote:

 Jeez, this has been a bad computer day for me.

 ls listings are just like Steve's.

I'm back to my figment of the imagination idea: this phantom
dirs-first ls listing is a delusion produced by too much mc use.


-- 
No no no, my fish's name is Eric, Eric the fish. He's an halibut. I am
not a looney! Why should I be tarred with the epithet looney merely
because I have a pet halibut?


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



ls sort order: new, bad, behaviour

2007-09-22 Thread Eric d'Alibut
Last night I installed, and then removed, the ftpd and proftpd debs,
in that order. Now I cannot by hook or crook get 'ls' to behave as it
did before those ftp experiments. 'ls' now sorts strictly by filename
-- including directories -- so that the latter are mixed in with
regular files in the output of 'ls'.

The last time I ran into this putting 'export LC_COLLATE=C' in .bashrc
remedied the unwanted behaviour. No such luck this time.

I notice in proftpd's postinst script a 'ListOption' configuration
variable was set. Did this somehow get lodged somewhere in a system
file such that even with the purge of proftpd it is still active?


Best regards,

-- 
No no no, my fish's name is Eric, Eric the fish. He's an halibut. I am
not a looney! Why should I be tarred with the epithet looney merely
because I have a pet halibut?


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: ls sort order: new, bad, behaviour

2007-09-22 Thread Benjamin A'Lee
On Sat, Sep 22, 2007 at 06:53:57PM -0400, Eric d'Alibut wrote:
 Last night I installed, and then removed, the ftpd and proftpd debs,
 in that order. Now I cannot by hook or crook get 'ls' to behave as it
 did before those ftp experiments. 'ls' now sorts strictly by filename
 -- including directories -- so that the latter are mixed in with
 regular files in the output of 'ls'.
 
 The last time I ran into this putting 'export LC_COLLATE=C' in .bashrc
 remedied the unwanted behaviour. No such luck this time.

Do 'printenv | grep LC_COLLATE' or 'locale' show the right setting?

 I notice in proftpd's postinst script a 'ListOption' configuration
 variable was set. Did this somehow get lodged somewhere in a system
 file such that even with the purge of proftpd it is still active?

I shouldn't think so, but it's not impossible (I can't see why it would
change system settings, but it could have done).

-- 
Benjamin A'Lee [EMAIL PROTECTED]
http://subvert.org.uk/~bma/
Now, now, dear man, this is not the time to be making enemies. -
Voltaire, on his deathbed, when a priest asked him to renounce Satan


signature.asc
Description: Digital signature


Re: ls sort order: new, bad, behaviour

2007-09-22 Thread s. keeling
Eric d'Alibut [EMAIL PROTECTED]:
  Last night I installed, and then removed, the ftpd and proftpd debs,

Glad I don't use 'em.

  in that order. Now I cannot by hook or crook get 'ls' to behave as it
  did before those ftp experiments. 'ls' now sorts strictly by filename
  -- including directories -- so that the latter are mixed in with
  regular files in the output of 'ls'.

I always preferred that to the alternatives.

  The last time I ran into this putting 'export LC_COLLATE=C' in .bashrc
  remedied the unwanted behaviour. No such luck this time.

I was about to recommend that.  That's what I use here:

 (0) heretic /home/keeling_ echo $LC_COLLATE
 C

(0) heretic /home/keeling_ ls -AlF
.Xauthority.fontconfig/  .lesshst.serverauth.3496.xinitrc*
.Xclients* .forward  .linuxcounter/  .serverauth.3517.xscreensaver
.Xmodmap   .funcs.list_signature .serverauth.3632
.xsession-errors
.Xresources.gaim/.macromedia/.serverauth.3680Mail/
.alias .gamix/   .mozilla/   .serverauth.4496News/
.aptitude/ .gconf/   .mplayer/   .signature  Xprintjobs/
.bash_history  .gconfd/  .muttrc@.slrn-tmpfile.asc   bak/
...

  I notice in proftpd's postinst script a 'ListOption' configuration
  variable was set. Did this somehow get lodged somewhere in a system
  file such that even with the purge of proftpd it is still active?

Could it have done something in the environment.  Anything odd in a
set listing?


-- 
Any technology distinguishable from magic is insufficiently advanced.
(*)http://blinkynet.net/comp/uip5.html  Linux Counter #80292
- -http://www.faqs.org/rfcs/rfc1855.htmlPlease, don't Cc: me.


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]



Re: ls sort order: new, bad, behaviour

2007-09-22 Thread Mumia W..

On 09/22/2007 05:53 PM, Eric d'Alibut wrote:

Last night I installed, and then removed, the ftpd and proftpd debs,
in that order. Now I cannot by hook or crook get 'ls' to behave as it
did before those ftp experiments. 'ls' now sorts strictly by filename
-- including directories -- so that the latter are mixed in with
regular files in the output of 'ls'.
[...]


Does ls -X give you the output you want?

If so, you can create an alias for that command in ~/.bashrc .

I hope this helps.



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]




Re: ls sort order: new, bad, behaviour

2007-09-22 Thread Eric d'Alibut
On 9/22/07, Benjamin A'Lee [EMAIL PROTECTED] wrote:

 Do 'printenv | grep LC_COLLATE' or 'locale' show the right setting?

I am beginning to think I am a victim of my addled pate. Have I been
using midnight commander too much? Am I looking for a fig newton of my
imagination, namely, an 'ls' that sorts directories first, and
ordinary files afterwards? Do others actually see that behaviour in
terminals?


-- 
No no no, my fish's name is Eric, Eric the fish. He's an halibut. I am
not a looney! Why should I be tarred with the epithet looney merely
because I have a pet halibut?


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED] 
with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]