Skip to content

Instantly share code, notes, and snippets.

Created Jul 29, 2015
What would you like to do?
toplevel venmo linting script
#!/usr/bin/env bash
# Usage:
# lint [file1] [file2]...
# With no arguments, lint any tracked files with modifications.
# Get into the path so that git-lint detects it.
GITROOT=`git rev-parse --show-toplevel`
export PATH="$PATH:$GITROOT/venmolint"
# The git-lint cache isn't reliable; we clear it before each run.
rm -rf ~/.git-lint/cache/
if [ $# -eq 0 ]
# without --tracked, git-lint will also lint untracked files.
git lint --tracked --force
git lint --force "$@"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment