delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2010/10/01/03:43:13

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,T_TO_NO_BRKTS_FREEMAIL
X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
In-Reply-To: <4CA492AA.6020104@charter.net>
References: <loom DOT 20100929T172802-227 AT post DOT gmane DOT org> <4CA492AA DOT 6020104 AT charter DOT net>
Date: Fri, 1 Oct 2010 09:42:57 +0200
Message-ID: <AANLkTinE_JABqqC=ST0F4zJL3gcR+yg6+HLPZSXZ6f6v@mail.gmail.com>
Subject: Re: use the list of files stored in a text file and process it
From: Csaba Raduly <rcsaba AT gmail DOT com>
To: cygwin AT cygwin DOT com
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Thu, Sep 30, 2010 at 3:37 PM, SJ Wright  wrote:
> I know one of the trip-ups I often have if I spend any time away from a
> L/Unix environment has to do with the "mv" command: I often forget that it
> prefers absolute paths from root folders (or in the case of Cygwin, virtual
> ones taken as real) or dot-dot-slash relative path syntax to just
> "/god-directory/" or what-have-you. Many other commands, particularly ls and
> ln -s, are likewise "particular about their paths."

(general "you" meant below)
Unix commands are not "particular about their paths". They just trust
you to give the correct file names. If the file name does not begin
with a slash, it is relative to the current directory. That may or may
not be what you intended. Using absolute paths ensures that the
meaning of a filename is not influenced by the current directory; but
using relative paths is often shorter. If you have trouble remembering
what the current directory is, try setting the prompt to always print
the current directory, like this:

 PS1='\[\e]0;\w\a\]\n\[\e[32m\]\u@\h \[\e[33m\]\w\[\e[0m\]\n\t \$ '

-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ L w++$ tv+ b++ DI D++ 5++
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019