summaryrefslogtreecommitdiffstats
path: root/pkgs/by-name/vi/vim-vint/remove-pkg-resources.patch
blob: 2613a1ef6a7215d876b661bca55bac307d057a1f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
diff --git a/vint/linting/cli.py b/vint/linting/cli.py
index 55db52e..97f33e1 100644
--- a/vint/linting/cli.py
+++ b/vint/linting/cli.py
@@ -1,7 +1,6 @@
 import sys
 from argparse import ArgumentParser
 from pathlib import PosixPath
-import pkg_resources
 import logging
 
 from vint.linting.linter import Linter
@@ -150,14 +149,7 @@ class CLI(object):
 
 
     def _get_version(self):
-        # In unit tests, pkg_resources cannot find vim-vint.
-        # So, I decided to return dummy version
-        try:
-            version = pkg_resources.require('vim-vint')[0].version
-        except pkg_resources.DistributionNotFound:
-            version = 'test_mode'
-
-        return version
+        return "@version@"
 
 
     def _adjust_log_level(self, env):