Skip to content

Instantly share code, notes, and snippets.

@wrouesnel
Created April 4, 2019 23:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wrouesnel/49b353d5564879feae7163722f5e039b to your computer and use it in GitHub Desktop.
Save wrouesnel/49b353d5564879feae7163722f5e039b to your computer and use it in GitHub Desktop.
Wrapper script for mypy to allow clickable lines in Pycharm.
#!/bin/bash
# Parse the mypy output so we get full-filepaths
while read l ; do
relpath="$(echo $l | cut -d':' -f1)"
echo "$(readlink -f "$relpath"):$(echo $l | cut -d':' -f2-)"
done < <(mypy "$@")
exit $?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment