Comments (3)
Nice! I can see when I find some time and contribute with a PR with the drivers I have.
One suggestion is to name the custom drivers with a prefix e.g. custom-gitattributes-
, to avoid conflicts. Silly example to illustrate what I mean.
# gitattributes
# include https://github.com/alexkaratarakis/gitattributes/blob/master/sql.gitattributes
*.sql linguist-detectable=true
*.sql linguist-language=sql
*.sql diff=custom-gitattributes-sql
# override diff driver
*.sql diff=custom-andreineculau-sql
# gitconfig
# include https://github.com/alexkaratarakis/gitattributes/blob/master/sql.gitconfig
[diff "custom-gitattributes-sql"]
textconv = sql-formatter
# add my own diff drivers
[diff "custom-andreineculau-sql"]
textconv = sql-formatter --uppercase
``
from gitattributes.
Sorry for the delay!
I think defining custom diff drivers is reasonable for the scope of this repo.
We could put them in files ending in gitconfig
since custom diff drivers are supposed to go there, following the existing pattern that this repo and the gitignore
repo is following (but I am open to other suggestions of course). Also, possibly in a dedicated folder for custom diff drivers.
from gitattributes.
Yeah, that looks intuitive. 👍
from gitattributes.
Related Issues (20)
- Add *.cjs and *.mjs
- Treating lockfiles as binary (no diff) is too subjective HOT 1
- Add TinaCMS Template
- Add terraform and hcl files for hashiCorp products
- add markdown in gitattributes HOT 2
- Add WordPress CMS template
- create "gitattributes organization" HOT 9
- Rationale for specifying line endings in `.gitattributes` generally, and specifically for `*.ps1` files. HOT 1
- default config '* text=auto' is placed in multiple templates
- folder ".override/" in gitattributes
- Inconsistent *.pdf attributes HOT 2
- What's the project status? HOT 5
- Consider splitting "Web.gitattributes" into "Jekyll.gitattributes" and "Node.gitattributes" similar to github/gitignore HOT 1
- Use "Global" and "community" folders like github/gitignore HOT 1
- Consider `gh` CLI extension? HOT 3
- Consider removing "*.thing text" from lots of .gitattributes files? HOT 2
- Get in touch with @gitattributes? HOT 10
- Consider clarifying if you can have more than 1 `.gitattributes` file, and how specific the file name(s) need to be... HOT 1
- Directly set a percentage for a specific language in a .gitattributes file. HOT 1
- Generator output contains duplicate lines HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gitattributes.