[nSLUG] Removing spaces from file names - note, long lines

Oliver Doepner odoepner at gmail.com
Fri Nov 14 11:09:11 AST 2014


Localized file names? Are you kidding?
I am sure Linus will never accept such non-sense into his kernel tree.
Which lets me sleep soundly at night. :o)

On Thu, Nov 13, 2014 at 10:49 AM, George N. White III <gnwiii at gmail.com>
wrote:

> On Wed, Nov 12, 2014 at 10:41 PM, Hatem Nassrat <hnassrat at gmail.com>
> wrote:
>
>> Hi Vlado,
>>
>> On Wed Nov 12 2014 at 10:32:22 PM Vlado Keselj <vlado at dnlp.ca> wrote:
>>
>>>
>>> This one-liner does not do the same operation.  My main goal was
>>> to turn one or any chosen filenames that look like:
>>>
>>> Joe, Jack & Jane's document (version # 1) [draft].doc
>>>
>>> into something like:
>>>
>>> Joe--Jack_and_Jane-s_document_-version_=23_1-_-draft-_.doc
>>>
>>
>> Saw your perl, honestly didn't mentally fully compile it, but it seems
>> like it would do the transformation as described. What is the reasoning /
>> requirements for the use of this kind of transformation, is it so you can
>> revert back to the original name?
>>
>
> It might be useful to mention the possibility of replacing the file name
> with the inode number or (as in git) SHA-1 hashes.    You can keep a
> database to associate all sorts of metadata with inode numbers or hashes,
> including "original_name", "8dot3_name", "ascii_name", "UTF-8_name", etc.
> Many years ago mainframes were limited to short filenames and about 64
> characters (uppercase, numbers, and a few punctuation symbols).  Libraries
> to support ASCII names began to appear, so you could live in an "ASCII"
> namespace while the system used simple names.  This did require a translation
> tool to figure out the ASCII version of a name mentioned in system logs.
> In many environments it would be helpful to allow the filenames visible to
> users change with the locale.
>
> --
> George N. White III <aa056 at chebucto.ns.ca>
> Head of St. Margarets Bay, Nova Scotia
>
> _______________________________________________
> nSLUG mailing list
> nSLUG at nslug.ns.ca
> http://nslug.ns.ca/mailman/listinfo/nslug
>
>


-- 
Oliver Doepner
Software Engineer
http://oliver.doepner.net/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nslug.ns.ca/pipermail/nslug/attachments/20141114/b710c22b/attachment.html>


More information about the nSLUG mailing list