On Thu, Dec 17, 2020 at 05:19:24PM -0500, Richard Kimberly Heck wrote: > Obviously, we could just use the parent directory search thing. But is there > a reason not just to check the return value of "git status" etc? I would > think this was also an easier way to see if a file is under version control. > But perhaps it is less portable. Pavel, you must have thought about this?
I don't remember all the discussions involved, it's long time ago, one would need to dig through archives, I even believe that orginal idea was actually external calls. Thinking from top of my head, both solutions have pros and cons. E.g. external call might need more complex error checking (e.g. "git command not found" vs "git returned error X", differences across OSes), parsing problems (output messaging across different git versions, different locales or whatnot). Checking existence of a single dir/file in all parent dirs does not look as that bad alternative in this light... Two possible ways how to address the original problem - improve current detection for registering, in a similar way we do in findFile - or explicitly show all VCS registrer functions in the menu for all backends (File>VCS>"register in {rcs,cvs,svn,git}"). To the somewhat complimentary question - what should be the default VCS used in case the file is not tracked? I tend to think that RCS is a good one, because its way less intrusive (single ,v file next to your file) and you don't need machinery to handle errors around creating new repositories before you can actually add the file into it. ...from a totally different perspective I am not sure how good idea is trying to push less tech-savvy people to actualy use our VCS machinery unless you want to be constantly behind their back any time some VCS-related problem happens. LyX handling too barebone to actually solve underlying issues within any of the VCS backends we have... Pavel -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users