How to determine files that are subjected to filter via gitattributes when filter is executed?
- by rasjani
I have bunch of ruby scripts in a git repository and it seems to be really hard to enforce people to write properly indented code.
I also have a small ruby script that formats to code to specific standard and now i would like to run that as a a filter script so that junk wont get committed into repository.
echo "*.rb filter=rubyfilter" > .gitattributes
echo "[filter \"rubyfilter\"]" >> .git/config
echo " clean = /home/rasjani/bin/rbeauty" >> .git/config
echo " smudge = /home/rasjani/bin/rbeauty" >> .git/config
does the dirty trick git side but the ruby script should then process the files affected:
how / where do i look those up from ?