On 4/10/2017 11:48 AM, Thomas wrote:

Actually, I got a batch file that reads the file filter settings from another file and creates the binary-glob and the ignore-glob files on the fly before an addremove and a commit (crlf-glob is not created and only contains an asterisk now).

Why do this on every commit?

The whole point of the versioned settings is that they can be set once and stored, and are carried with the repository into every working folder on fossil open.

You figure out what files never need saving, and put globs in ignore-glob that match them. Note that the globs are matched on the whole pathname in the working folder, so you can exclude entire folders too if that is handy. Which is nice for things like the Release and Debug folders that VS tends to create in its projects. You will want to work out carefully what files your IDE needs to be treated like source code, which of those are binary (a stupid mistake made by too many IDEs is to use binary files for project configuration which makes using version control harder than necessary), and which files are build products.

Something like this is my usual starting point for ignore-glob for a lot of projects. I usually create ignore-glob right after creating the repository and before checking things in. I always include globs for whatever backup files get created by my text editors, all the build products I can identify, and if practical, any folders created by building.

~*,*.bak
*.o,*.d
*.obj,*.exe,*.dll
*.bin,*.hex
*Build*/*
*build*/*
ship/*
*.zip,*.tar*

The fossil extras command is useful for finding things that belong in ignore-glob. It lists the files that fossil addremove would add or fossil clean would delete.

IDEs come with an extra burden. They always seem to be written by people that believe there is no world outside of the IDE, and especially no version control. Worse, they also seem to be hostile to all the other IDE developers, and highly resistant to any sort of standardized naming of things. On the positive side, there is this project at Github where people are tracking what to tell Git to ignore. The syntax isn't identical for fossil, but the data is still valuable.

  https://github.com/github/gitignore

Now I wonder how hard it would be to add support for comments to fossil's versioned settings files, as well as the [Aa] to the globs. Comments are probably easy, but I suspect the glob syntax is tied to SQLite. I may look into that.
--

Ross Berteig                               r...@cheshireeng.com
Cheshire Engineering Corp.           http://www.CheshireEng.com/
+1 626 303 1602

_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to