mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-15 21:14:35 +02:00
...
This commit is contained in:
4
setup.py
4
setup.py
@@ -35,12 +35,12 @@ build_dir = 'build'
|
||||
constants = os.path.join('kitty', 'constants.py')
|
||||
with open(constants, 'rb') as f:
|
||||
constants = f.read().decode('utf-8')
|
||||
appname = re.search(r"^appname = '([^']+)'", constants, re.MULTILINE).group(1) # type: ignore
|
||||
appname = re.search(r"^appname: str = '([^']+)'", constants, re.MULTILINE).group(1) # type: ignore
|
||||
version = tuple(
|
||||
map(
|
||||
int,
|
||||
re.search( # type: ignore
|
||||
r"^version = Version\((\d+), (\d+), (\d+)\)", constants, re.MULTILINE
|
||||
r"^version: Version = Version\((\d+), (\d+), (\d+)\)", constants, re.MULTILINE
|
||||
).group(1, 2, 3)
|
||||
)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user