mirror of
https://github.com/fedora-python/tox-current-env.git
synced 2024-12-23 16:46:14 +01:00
Use sysconfig instead of hardcoded paths
This commit is contained in:
parent
bb79c6d405
commit
5d3802da93
@ -1,6 +1,7 @@
|
||||
import argparse
|
||||
import platform
|
||||
import sys
|
||||
import sysconfig
|
||||
import warnings
|
||||
from pathlib import Path
|
||||
from typing import Set
|
||||
@ -125,13 +126,13 @@ class CurrentEnv(PythonRun):
|
||||
return None
|
||||
|
||||
def env_bin_dir(self):
|
||||
return Path(sys.prefix) / "bin"
|
||||
return Path(sysconfig.get_path("scripts"))
|
||||
|
||||
def env_python(self):
|
||||
return sys.executable
|
||||
|
||||
def env_site_package_dir(self):
|
||||
return Path(sys.prefix) / "lib"
|
||||
return Path(sysconfig.get_path("purelib"))
|
||||
|
||||
@property
|
||||
def installer(self):
|
||||
|
Loading…
Reference in New Issue
Block a user