Re: [Eug-lug] ls script help

2009-02-03 Thread Bob Miller
Feb 2, 2009 at 2:14 PM, horst wrote: > >> Date: Fri, 30 Jan 2009 23:03:57 -0800 (PST) >> From: Neil Parker >> Subject: Re: [Eug-lug] ls script help > > ...> >> >> timestamps. "tar", for example, archives only one-second-resolution >> timesta

Re: [Eug-lug] ls script help

2009-02-02 Thread Neil Parker
Horst wrote, > Ahh -- Octal ! "twelve-characer octal strings". I used my hex viewer to >look at a very simple tar file before posting, but couldn't make sence of >it. On my system (a full install of Slackware 12.1), I found a description of the tar format in the file /usr/include/tar.h. (You

Re: [Eug-lug] ls script help

2009-02-02 Thread horst
Date: Fri, 30 Jan 2009 23:03:57 -0800 (PST) From: Neil Parker Subject: Re: [Eug-lug] ls script help ...> timestamps. "tar", for example, archives only one-second-resolution timestamps, as twelve-characer octal strings...this is mandated by a POSIX standard, and for the sak

Re: [Eug-lug] ls script help

2009-01-30 Thread Neil Parker
Horst wrote, >To which extend do standard commands, like stat or tar actually support >floating point time stamps? (or fractions of a second). I always only >seem to see integers reported/stored. The resolution of timestamps reported by "stat" depends on the filesystem. Classic UNIX filesystems

Re: [Eug-lug] ls script help

2009-01-30 Thread Bob Miller
On Fri, Jan 30, 2009 at 1:07 AM, horst wrote: > Interesting! > To which extend do standard commands, like stat or tar actually support > floating point time stamps? (or fractions of a second). I always only seem > to see integers reported/stored. /usr/bin/stat appears to print microsecond times

Re: [Eug-lug] ls script help

2009-01-30 Thread horst
Date: Thu, 29 Jan 2009 09:35:54 -0800 From: Bob Miller Horst, if you were serious about it, you could write a program to change the date, touch the file, and change the date again. I'd be surprised if the system time were changed for more than a millisecond. OK, I declare defeat :-) -- at lea

Re: [Eug-lug] ls script help

2009-01-29 Thread Ben Barrett
rom: Alan >>> Reply-To: Eugene Unix and Gnu/Linux User Group >>> To: Eugene Unix and Gnu/Linux User Group >>> Subject: Re: [Eug-lug] ls script help >>> >>> Mike Cherba wrote: >>>> >>>> On Wed, 2009-01-28 at 00:17 -080

Re: [Eug-lug] ls script help

2009-01-29 Thread David Duncan
gt; Date: Wed, 28 Jan 2009 00:39:43 -0800 >> From: Alan >> Reply-To: Eugene Unix and Gnu/Linux User Group >> To: Eugene Unix and Gnu/Linux User Group >> Subject: Re: [Eug-lug] ls script help >> >> Mike Cherba wrote: >>> >>> On Wed, 2009-01-28 a

Re: [Eug-lug] ls script help

2009-01-29 Thread Bob Miller
;> Date: Wed, 28 Jan 2009 00:39:43 -0800 >> From: Alan >> Reply-To: Eugene Unix and Gnu/Linux User Group >> To: Eugene Unix and Gnu/Linux User Group >> Subject: Re: [Eug-lug] ls script help >> >> Mike Cherba wrote: >>> >>> On Wed, 2009-01-

Re: [Eug-lug] ls script help

2009-01-28 Thread horst
Alan Reply-To: Eugene Unix and Gnu/Linux User Group To: Eugene Unix and Gnu/Linux User Group Subject: Re: [Eug-lug] ls script help Mike Cherba wrote: On Wed, 2009-01-28 at 00:17 -0800, Alan wrote: Which apparently doesn't change the ctime on linux. Yup. Which is why you change the system ti

Re: [Eug-lug] ls script help

2009-01-28 Thread Alan
Mike Cherba wrote: On Wed, 2009-01-28 at 00:17 -0800, Alan wrote: Which apparently doesn't change the ctime on linux. Yup. Which is why you change the system time. Ccime is maintained by the system for good reasons. I know I have used a *nix in the past 10 years in which touch could cha

Re: [Eug-lug] ls script help

2009-01-28 Thread Mike Cherba
On Wed, 2009-01-28 at 00:17 -0800, Alan wrote: > Which apparently doesn't change the ctime on linux. > Yup. Which is why you change the system time. Ccime is maintained by the system for good reasons. If everything seems to be going well, you have obviously overlooked something. __

Re: [Eug-lug] ls script help

2009-01-28 Thread Alan
Alan wrote: Mike Cherba wrote: On Wed, 2009-01-28 at 00:21 -0700, horst wrote: Conversely, is there any official unix command (or hack for that matter) that allows you to arbitrarily change the ctime on a life system (anything beyond throwing a hex editor at an unmounted file system) Well,

Re: [Eug-lug] ls script help

2009-01-28 Thread Alan
Mike Cherba wrote: On Wed, 2009-01-28 at 00:21 -0700, horst wrote: Conversely, is there any official unix command (or hack for that matter) that allows you to arbitrarily change the ctime on a life system (anything beyond throwing a hex editor at an unmounted file system) Well, As for hacks,

Re: [Eug-lug] ls script help

2009-01-28 Thread Mike Cherba
On Wed, 2009-01-28 at 00:21 -0700, horst wrote: > Conversely, is there any official unix command (or hack for that matter) > that allows you to arbitrarily change the ctime on a life system (anything > beyond throwing a hex editor at an unmounted file system) > Well, As for hacks, the simplest i

Re: [Eug-lug] ls script help

2009-01-27 Thread horst
Date: Mon, 26 Jan 2009 22:03:54 -0800 From: Hal Pomeranz Reply-To: Eugene Unix and Gnu/Linux User Group To: Eugene Unix and Gnu/Linux User Group Subject: Re: [Eug-lug] ls script help ...> # all files, recursively, created within the past 30 days find . -ctime -30 Bzzt! Incorrect! &qu

Re: [Eug-lug] ls script help

2009-01-27 Thread horst
Date: Mon, 26 Jan 2009 22:14:32 -0600 From: Chris St. Pierre Reply-To: Eugene Unix and Gnu/Linux User Group To: notanathe...@yahoo.com, Eugene Unix and Gnu/Linux User Group Subject: Re: [Eug-lug] ls script help ...> # remove files created within the past seven days find . -ctime

Re: [Eug-lug] ls script help

2009-01-27 Thread turtle
On Monday 26 January 2009 22:03:54 Hal Pomeranz wrote: > > Use find instead of ls: > > Good advice. > There are several examples you might find useful in my "Command-Line > Kung Fu" presentation: > > http://www.deer-run.com/~hal/UnixCommandLineKungFu.pdf Wow Hal! That Command Line Kung Fu i

Re: [Eug-lug] ls script help

2009-01-26 Thread Keith Bucher
> There are several examples you might find useful in my "Command-Line > Kung Fu" presentation: > http://www.deer-run.com/~hal/UnixCommandLineKungFu.pdf Hal's presentation is a good one, two additional tricks that I've found useful are: * If you're dealing with files that contain whitespace

Re: [Eug-lug] ls script help

2009-01-26 Thread Hal Pomeranz
> Use find instead of ls: Good advice. > # all files, recursively, created within the past 30 days > find . -ctime -30 Bzzt! Incorrect! "ctime" is not "created time", it's "inode change time"-- i.e., the last time you used chmod/chown/etc on the file. There's no way to look at a file in Unix

Re: [Eug-lug] ls script help

2009-01-26 Thread Chris St. Pierre
On Mon, Jan 26, 2009 at 9:28 PM, Mr O wrote: > ls -ltr shows creation date from oldest to newest but can I narrow that down > and say only print the last 30 days changes? What about a recursive search? > How about a variable showing only the last 14 days or 7 days? How about > narrowing down t

[Eug-lug] ls script help

2009-01-26 Thread Mr O
ls -ltr shows creation date from oldest to newest but can I narrow that down and say only print the last 30 days changes? What about a recursive search? How about a variable showing only the last 14 days or 7 days? How about narrowing down to a specific date after finding what was needed? Next,