Skip to content

Commit

Permalink
mypy: use python from the current environment (#627)
Browse files Browse the repository at this point in the history
Allows to use a global `mypy` installation and have it recognize virtualenvs
  • Loading branch information
rainx0r authored Aug 8, 2024
1 parent 0396b66 commit 9f0ce1d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/lint/linters/mypy.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ return {
'--no-color-output',
'--no-error-summary',
'--no-pretty',
'--python-executable',
function()
return vim.fn.exepath 'python3' or vim.fn.exepath 'python'
end
},
parser = require('lint.parser').from_pattern(
pattern,
Expand Down

0 comments on commit 9f0ce1d

Please sign in to comment.