delorie.com/archives/browse.cgi   search  
Mail Archives: geda-user/2018/07/06/11:48:48

X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f
X-Recipient: geda-user AT delorie DOT com
X-Originating-IP: 84.92.49.234
Date: Fri, 6 Jul 2018 16:47:28 +0100
From: Chris Green <cl AT isbd DOT net>
To: geda-user AT delorie DOT com
Subject: Re: [geda-user] gschem - backup file names aren't differentiated in
the 'Open Recent' menu, very confusing!
Message-ID: <20180706154728.GA11415@esprimo>
Mail-Followup-To: geda-user AT delorie DOT com
References: <20180706144347 DOT GA10675 AT esprimo>
<alpine DOT DEB DOT 2 DOT 20 DOT 1807061713060 DOT 5580 AT nimbus>
MIME-Version: 1.0
In-Reply-To: <alpine.DEB.2.20.1807061713060.5580@nimbus>
User-Agent: Mutt/1.6.1 (2016-04-27)
X-Spam-Level:
Reply-To: geda-user AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: geda-user AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Fri, Jul 06, 2018 at 05:24:51PM +0200, Roland Lutz wrote:
> On Fri, 6 Jul 2018, Chris Green wrote:
> > If I look in the 'File'->'Open Recent' menu in gschem I see:-
> > 
> >    0. bbbpsu.sch
> >    1. socket.sym
> >    2. odinbbb.sch
> >    3. odinbbb.sch
> >    4. 12n.sch
> >    5. odinbbb.sch
> > 
> > 
> > This really isn't very useful! :-)
> 
> Are these entries actually referring to files in the directory you listed,
> or do you have identically-named files in different directories?  If you
> hover the mouse over the menu item, you will get a tooltip showing the full
> path.
> 
Ah, I hadn't seen the tooltip.  It turns out that the 'Open Recent'
list includes files in different directories which don't even exist
any more.  So the names are right, it's not showing backup files, it
was just bad luck that there were similar looking names (and numbers
of files) in the same directory.


> Did you do anything unusual, such as opening the backup file directly in the
> editor, or moving the file to another directory and opening it there?
> 
I have moved some files around while rationalising my directory
structure.


> > While I'm at it why are there both xxxxx.sch~ and #xxxxx.sch# files?
> 
> Files with a trailing tilde are backup files, while files with a leading and
> trailing number sign are autosave files which are used to recover the
> work-in-prgoress in case something went wrong.
> 
When are backup files created?  


> > Plus, while I'm at it, # is a really rubbish character to use because
> > it's the comment marker in most (Unix/Linux) shells.
> 
> This is the usual naming convention for autosave files on POSIX systems.
> 
OK, I've not come across it before, and I have been using/programming
on Unix systems since the 1980s!  :-)


> In the unusual case that you need to specify the name of an autosave file to
> a shell, there are multiple ways to do so: the comment character is only
> interpreted at the beginning of a word, so you can give the file name as
> ./#foo.sch#, or you could just escape the character or the whole file name
> according to your shell's escaping mechanism, like \#foo# or '#foo#'.
> 
Yes, I'm familiar with shell quoting etc. but something that forces
you to use it *by design* seems not a good idea to me.  However as it
does seem to be a convention I'll live with it and not complain. :-)


I do think that the 'Open Recent' list could do with some improvement
though, e.g. it could check for duplicates and/or if there are any
indicate different directories.

Thanks for the very full and helpful explanation.

-- 
Chris Green

- Raw text -


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