Open Wilfred opened 2 years ago
I would like to see configurable filetype associations, like the ones present in ripgrep
. Some files may have custom extensions, but may use syntax trees from other languages. An example is the new Kicad project files, where they are essentially S-exprs, and should be diffed as such
@crides agreed, configurable file associations would be nice.
(FWIW I'm not sure Kicad would work well as there's no generic s-expression parser in difftastic today.)
Kicad actually works fairly well. I simply modded the file detection to map kicad files to Common Lisp. The only thing that's a bit hard is because it's not manually edited (well not most of the time anyway) and the order of some of the elements don't actually matter, but the unorderedness would make diffing possibly very hard. So for now, everything works well enough.
For example,
TARGETS
is usually python syntax (specifically starlark), but has no file extension.