From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Xah Newsgroups: gmane.emacs.help Subject: Re: (emacs+unix): How to have a file-name containing slashes, angle-brackets, etc? Date: Sun, 24 Aug 2008 12:12:38 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: <9e31b345-4cec-4ea6-8d63-d66b8355da06@p10g2000prf.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1219607006 7600 80.91.229.12 (24 Aug 2008 19:43:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 24 Aug 2008 19:43:26 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Aug 24 21:44:19 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KXLVa-0007Kq-4O for geh-help-gnu-emacs@m.gmane.org; Sun, 24 Aug 2008 21:44:18 +0200 Original-Received: from localhost ([127.0.0.1]:35857 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KXLUc-0003wL-9h for geh-help-gnu-emacs@m.gmane.org; Sun, 24 Aug 2008 15:43:18 -0400 Original-Path: news.stanford.edu!newsfeed.stanford.edu!postnews.google.com!n33g2000pri.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 120 Original-NNTP-Posting-Host: 24.6.185.159 Original-X-Trace: posting.google.com 1219605158 29491 127.0.0.1 (24 Aug 2008 19:12:38 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Sun, 24 Aug 2008 19:12:38 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: n33g2000pri.googlegroups.com; posting-host=24.6.185.159; posting-account=bRPKjQoAAACxZsR8_VPXCX27T2YcsyMA User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10_4_11; en) AppleWebKit/525.18 (KHTML, like Gecko) Version/3.1.2 Safari/525.22, gzip(gfe), gzip(gfe) Original-Xref: news.stanford.edu gnu.emacs.help:161597 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:56941 Archived-At: On Aug 24, 5:31 am, Nikolaj Schumacher wrote: > Xah wrote: > > Unix is the worst, they pretty much just allow > > alphanumerics and not even space. If you have anything like =E2=80=9C,= =3D(); > > \'"~&-=E2=80=9D etc, you can expect most shell tools to erase you disk) > > Actually unix systems allow pretty much every character except / and the > null character. To say that unix allows much wider chars in file names is like saying mud is the best medium for sculpture. Unix file names, for much of its history up to perhaps mid 2000s, effectively just allows alphanumerics plus hyphen =E2=80=9C-=E2=80=9D and u= nderscore =E2=80=9C_=E2=80=9D. As a contrast for comparison, Mac's file names often c= ontain punctuations such as =E2=80=9C,$#!*()=E2=80=9D and space, but also allows n= on-ascii such as euro lang chars =C3=A7=C3=B6 printer's symbols =E2=80=A0=E2=80=A1=C2=B0 euro lang puncs =C2=AB=C2=BB=C2=A1 math =E2=89=88=E2=88=AB=C2=B5=E2=88=82=C6=92=CF=80=E2=89=A0=E2=89=A4=E2=89= =A5=E2=88=9E special symbols =E2=84=A2=C2=AE=C2=A9=C2=A3=C2=A2 etc since the early 1990 or before. ascii punctuations chars and non-ascii chars such as above are also allowed in filenames in Windows since about Microsoft Windows NT in late 1990s or earlier. Tools in MacOS (such as AppleScript) and Windows, support, expect, these chars in file names. Sure, you can use many non-alphanumeric chars besides hyphen and underscore in unix, but the system is simply not designed for it. Majority of unix tools, including file name listing, will chock and break if your filename contain these chars. The chocking doesn't actually give you a nice error message, but silently break and often resulting in unexpected and unpredicable behavior. In short, it's just not designed for it. Issues like these often perpetuate the myth that unix is =E2=80=9Cpowerful= =E2=80=9D, but in fact it's just raw and no-design. I wrote a essay describing this situation... here: The Nature of the =E2=80=9CUnix Philosophy=E2=80=9D http://xahlee.org/UnixResource_dir/writ/unix_phil.html plain text version follows: --------------------------- The Nature of the =E2=80=9CUnix Philosophy=E2=80=9D Xah Lee, 2006-05 In the computing industry, especially among unix community, we often hear that there's a =E2=80=9CUnix Philosophy=E2=80=9D. In this essay, i dis= sect the nature and characterization of such =E2=80=9Cunix philosophy=E2=80=9D, as h= ave been described by Brian Kernighan, Rob Pike, Dennis Ritchie, Ken Thompson, and Richard P Gabriel et al, and in recent years by Eric Raymond. There is no one definite set of priciples that is the so-called =E2=80=9Cun= ix philosophy=E2=80=9D, but rather, it consistest of various slogans developed over the decades by unix programers that purport to describe the way unix is supposed to have been designed. The characteristics include: =E2=80=9Ckeep it simple=E2=80=9D, =E2=80=9Cmake it fast=E2=80=9D, =E2=80=9C= keep it small=E2=80=9D, =E2=80=9Cmake it work on 99% of cases, but generality and correctness are less important=E2=80=9D, =E2=80=9Cdiversity rules=E2=80=9D, =E2=80=9CUser interface is not important= , raw power is good=E2=80=9D, =E2=80=9Ceverything should be a file=E2=80=9D, =E2=80=9Carch= itecture is less important than immediate workability=E2=80=9D. Often, these are expressed by chantibl= e slogans that exhibits juvenile humor, such as =E2=80=9Csmall is beautiful= =E2=80=9D, =E2=80=9CKISS (Keep It Simple, Stupid)=E2=80=9D. Suppose, we take a team of student programers to produce a large software system. When the software is done, give it to software critics to analyze and come up with some principles that characterize its design decisions, without disclosing the nature of the programers. The characterization of such software, will more or less fit the descriptions of the =E2=80=9CUnix Philosophy=E2=80=9D as described in diffe= rent ways by various unix celebrities. For example, it would focus on implementation simplicity as opposed to interface simplicity. It will not be consistent in user interface, but exhibits rawness. It would be correct only for most cases, as opposed to mathematically correct or generic. It would employ simplistic data structures and formats such as text-files with rows of lines and space separated columns, as opposed to a structured system or binary format that requires a spec. It would be speedy, but less on scalability. It would consists of many small programs, as opposed to one large system with inter-dependent components. It would be easy to patch and port, but difficult to upgrade its structure or adapt entirely new assumptions. The essence of this theory is that when a software is produced for real world use, it is necessary that it works in some acceptable way, otherwise the software will be continuously debugged and refined. A software system written by a bunch of student or otherwise under- educated programers, but refined long enough for acceptably practical, real world use, will necessarily develop characteristics that is known as the Unix Philosophy. Xah =E2=88=91 http://xahlee.org/ =E2=98=84