Skip to content

Commit

Permalink
Consolidate Git configuration
Browse files Browse the repository at this point in the history
Another 72-column wide game of "typography tetris" follows, interspersed
with TODOs and rambling self-reminders that I'm probably going to forget
later anyway:

git-config(1)
-------------

* Replace each different `textconv` handler with a call to a shellscript
  which unifies this whole mess. That one-line wrapper for `docx2txt` is
  retarded and should never have existed in the first place (if only the
  author had defaulted to using STDOUT instead of a .txt file, eh?).

* Add to aforementioned script a diffing helper for comparing compressed
  archives. Make sure to use `bsdtar -vtf` first before trying any other
  solution.

less(1), lynx(1)
----------------

* Leverage `LESSOPEN` to prettyprint JSON and anything quacking like XML
  or SGML. Follow sketchy conventions and name the script `.lessfilter`.

* Configure Lynx's keybindings so it feels like an actual pager program.

* Figure out why Lynx's source-view isn't being reformatted, and fix the
  startpage to show recent browsing history (or at least bookmarks).

Darwinisms
----------

* Separate the macOS-specific crap from the shared stuff so we keep this
  repository DRY and free of copy+pasta. Organise `./etc/install/` so we
  can add OpenBSD-related installer files for quicker station setup.

* Find a way to always extract archives to a single directory unless the
  only top-level file *is* a directory. Kind of like Apple's Finder, but
  without all the "Darwinisms" (__MACOSX, .DS_Store, ._*, etc).
  • Loading branch information
Alhadis committed Jan 8, 2018
1 parent 933f908 commit b53fc78
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 15 deletions.
36 changes: 23 additions & 13 deletions .gitconfig
Original file line number Diff line number Diff line change
@@ -1,19 +1,7 @@
[user]
name = Alhadis
email = gardnerjohng@gmail.com
signingkey = 895D24EE
[credential]
helper = osxkeychain
[diff]
renames = copies
[diff "word"]
textconv = docx2txt
[diff "exif"]
textconv = exiftool -x FileName -x Directory
[diff "bin"]
textconv = hexdump -v -C
[push]
default = simple
signingkey = C57044A83594344A
[core]
editor = /usr/local/bin/emacs
excludesfile = ~/.files/etc/.gitignore-global
Expand All @@ -25,7 +13,29 @@
co = checkout
r = remote --verbose
s = status
[credential]
helper = osxkeychain
[diff]
renames = copies
[diff "bin"]
textconv = hexdump -v -C
cachetextconv = true
[diff "exif"]
textconv = exiftool -x FileName -x Directory
cachetextconv = true
[diff "ps"]
textconv = ps2ascii
cachetextconv = true
binary = true
[diff "odt"]
textconv = odt2txt
cachetextconv = true
[diff "docx"]
textconv = docx2txt
cachetextconv = true
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
required = true
[gpg]
program = gpg2
5 changes: 3 additions & 2 deletions etc/.gitattributes-global
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@
*.psd diff=exif

# Document diffs
*.docx diff=word
*.doc diff=word
*.docx diff=docx
*.doc diff=docx
*.odt diff=odt

0 comments on commit b53fc78

Please sign in to comment.