This being Unix, there are a million ways to do things.  Just for the
sake of curiosity, here are 0.0004% more of the possibilities.  I only
bring this up because I know several of my coworkers don't know about
these tricks, so I imagine some others out there might not either.

On 4/18/2014 4:17 AM, Stephan Beal wrote:
echo '' > .fossil-settings/ignore-glob

(Unless you're in DOS or the Windows shell) echo with zero arguments
just prints a newline.  So you can skip the quotes.

$ echo > .fossil-settings/ignore-glob

In bash (not csh), you can skip the echo too:

$ > .fossil-settings/ignore-glob

This will trigger file creation which is a side effect of redirection,
but since there's no command, there's nothing to write.

csh explicitly forbids an empty command pipeline, so use the ":"
quasi-command which is a no-op ("does nothing, successfully"):

% : > .fossil-settings/ignore-glob

Or if the file doesn't already exist, touch will create it in the
process of updating its timestamp:

$ touch .fossil-settings/ignore-glob

--
Andy Goth | <andrew.m.goth/at/gmail/dot/com>
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to