On 12/02/12 23:55, Joel Roth wrote:
Hi Shellsters,
I've got a directory structure like this:
./project1/bak/a.yml
./project1/bak/b.yml
./project2/bak/c.yml
./project2/bak/d.yml
I want to move the *.yml files into the corresponding parent directory.
I tried this:
for dir in `find -maxdepth
On Mon, Feb 13, 2012 at 09:50:08AM +, Chris Davies wrote:
> Joel Roth wrote:
> > ./project1/bak/a.yml
> > ./project1/bak/b.yml
> > ./project2/bak/c.yml
> > ./project2/bak/d.yml
>
> > I want to move the *.yml files into the corresponding parent directory.
>
> rename 's!(.*/)([^/]*)$!$1../$2!'
Joel Roth wrote:
> ./project1/bak/a.yml
> ./project1/bak/b.yml
> ./project2/bak/c.yml
> ./project2/bak/d.yml
> I want to move the *.yml files into the corresponding parent directory.
rename 's!(.*/)([^/]*)$!$1../$2!' project*/bak/*.yml
;-)
Chris
--
To UNSUBSCRIBE, email to debian-user-requ..
On Mon, Feb 13, 2012 at 10:12:14AM +0200, Andrei Popescu wrote:
> On Du, 12 feb 12, 20:01:05, Joel Roth wrote:
> > >
> > > for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml
> > > ../..; done
> >
> > Thanks, I got something like that to work.
>
> I would have tried something w
On Du, 12 feb 12, 20:01:05, Joel Roth wrote:
> >
> > for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml ../..;
> > done
>
> Thanks, I got something like that to work.
I would have tried something with find's '-execdir'
- no need to operate on find's output (not a good idea un
On Mon, Feb 13, 2012 at 01:44:21AM +, ACro wrote:
>
> > for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml .. ;
> > chdir
> > ../..; done
>
>
> Joel,
>
> try this, HTH:
>
> for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml ../..;
> done
Thanks, I got s
> for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml .. ; chdir
> ../..; done
Joel,
try this, HTH:
for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml ../..; done
Kind regards,
Andrew
--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
with a
Hi Shellsters,
I've got a directory structure like this:
./project1/bak/a.yml
./project1/bak/b.yml
./project2/bak/c.yml
./project2/bak/d.yml
I want to move the *.yml files into the corresponding parent directory.
I tried this:
for dir in `find -maxdepth 1 -type d`; do chdir $dir/bak; mv *.yml
igor wrote:
looked here?
http://www.ductape.net/~mitja/freeunix.shtml
http://www.omena.org/
Great stuff. First time I *ever* heard about something like this.
H
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
looked here?
http://www.ductape.net/~mitja/freeunix.shtml
http://www.omena.org/
--
igor <[EMAIL PROTECTED]>
pletisan
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Is there a Debian Linux based cheap (like the freeshell ones), one -time payment shell provider? If someone knows of any, please reply. I couldn't find in google.
Regards,
Deboo
-- Please don't Cc: me, I'm subscribed to the list.
On Mon, 21 Jul 2003, Jeff Schaller wrote:
> Boy, reminds me of the old "useless use of cat" award... I always
> use:
I've got a bunch of those on the shelf here, anyone need one?
Mike
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTE
try "sed -n 'x p; x q' filename "
That will print only line x
On Monday 21 July 2003 14:54, Rus Foster wrote:
> Hi All,
> No strictly on topic but can anyone think of a better way to print out
> line x of a file in Shell Script. Best I have so far is (in pseudo code)
>
> cat /tmp/file | head -$x |
Rus Foster said on Mon, Jul 21, 2003 at 11:54:21AM -0700:
> Hi All,
> No strictly on topic but can anyone think of a better way to print out
> line x of a file in Shell Script. Best I have so far is (in pseudo code)
>
> cat /tmp/file | head -$x | tail -$x+1
>
> Anything better or a perl one liner
On Mon, 21 Jul 2003, Rus Foster wrote:
> No strictly on topic but can anyone think of a better way to
> print out line x of a file in Shell Script. Best I have so far
> is (in pseudo code)
>
> cat /tmp/file | head -$x | tail -$x+1
>
> Anything better or a perl one liner?
Boy, reminds me of the ol
Hi All,
No strictly on topic but can anyone think of a better way to print out
line x of a file in Shell Script. Best I have so far is (in pseudo code)
cat /tmp/file | head -$x | tail -$x+1
Anything better or a perl one liner?
Cheers
Rus
--
www: http://jvds.com | Virtual Servers from just $1
also sprach Sven Burgener (on Mon, 05 Mar 2001 06:34:44PM +0100):
> Can one determine *when* a file was moved into a specific directory? I
> guess not, as that means making a change to the directory in question
> and not the file.
if you are only interested in one-level depth, then an
addition/cha
Hello
Can one determine *when* a file was moved into a specific directory? I
guess not, as that means making a change to the directory in question
and not the file.
Cheers
Sven
PS: Please *DO* CC: me. Thank you.
> Is there any way to SSH or telnet into an account, start a command line
> program such as an ftp session, get the download going, then log out and
> leave the process happeneing. I would like to be able to start downloading
> then close down the workstation from which I SSHed, and come back the n
On Mon, Jul 10, 2000 at 10:14:37PM -0400, Chris Mason wrote:
> Is there any way to SSH or telnet into an account, start a command line
> program such as an ftp session, get the download going, then log out and
> leave the process happeneing. I would like to be able to start downloading
> then clos
On Mon, Jul 10, 2000 at 10:14:37PM -0400, Chris Mason wrote:
> Is there any way to SSH or telnet into an account, start a command line
> program such as an ftp session, get the download going, then log out and
> leave the process happeneing. I would like to be able to start downloading
> then close
nohup it...
On Mon, 10 Jul 2000, Chris Mason wrote:
> Is there any way to SSH or telnet into an account, start a command line
> program such as an ftp session, get the download going, then log out and
> leave the process happeneing. I would like to be able to start downloading
> then close down
Chris Mason wrote:
> Is there any way to SSH or telnet into an account, start a command line
> program such as an ftp session, get the download going, then log out and
> leave the process happeneing. I would like to be able to start downloading
> then close down the workstation from which I SSHed,
Chris Mason wrote:
> Is there any way to SSH or telnet into an account, start a command line
> program such as an ftp session, get the download going, then log out and
> leave the process happeneing. I would like to be able to start downloading
> then close down the workstation from which I SSHed,
Is there any way to SSH or telnet into an account, start a command line
program such as an ftp session, get the download going, then log out and
leave the process happeneing. I would like to be able to start downloading
then close down the workstation from which I SSHed, and come back the next
day
25 matches
Mail list logo