Certain settings, like ignore-glob or binary-glob can have a really long list 
of items, which may be edited from time to time.
Ideally, the global setting should have the ones that apply to all repos, while 
the local setting only the ones that apply only to that specific repo.

The problem is once you decide to use the local setting you need to specify the 
whole long list of items again for each repo.  And if you later change the 
global setting you need to remember to redefine all local settings for repos 
that include more items in the same setting to include the changes of the 
global setting.

My suggestion is this:

Have some form of shorthand notation – a text replacement macro, if you like – 
(like the string “~global~”, for example – or some other that is very unlikely 
to be an actual filename – or even something that is impossible to be a 
filename depending on the underlying OS), to let one import all the global 
settings for the given setting when specifying the local setting.

So, if the global setting is

binary-glob          (global) 
*.bin,*.bmp,*.com,*.dll,*.ico,*.exe,*.gif,*.jpg,*.mdb,*.mp3,*.mp4,*.obj,*.pdf,*.png,*.rar,*.jar,*.res,*.rtf,*.wav,*.zip,*.ppu,*.o

and the local setting needs to add to the above list just one item (*.pmp), one 
could do this:

fossil set binary-glob ~global~,*.pmp

(where ~global~ can appear anywhere, first, in-between, or last) and fossil set 
will display (in this case):

binary-glob          (local) 
*.bin,*.bmp,*.com,*.dll,*.ico,*.exe,*.gif,*.jpg,*.mdb,*.mp3,*.mp4,*.obj,*.pdf,*.png,*.rar,*.jar,*.res,*.rtf,*.wav,*.zip,*.ppu,*.o,*.pmp

However, the substitution of (macro) ~local~ should occur only at run-time so 
that a possible later update of the global setting will be automatically 
carried over to all local settings using ~global~

I hope I described this well enough to make sense.  I also hope you see the 
usefulness of what I’m proposing.  (Well, at least if you normally maintain 
more than just a few repos.)

Thanks.
_______________________________________________
fossil-users mailing list
[email protected]
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to