Skip to content

Commit cf91518

Browse files
committed
Simpler setuptools_scm and setuptools_conda usage
1 parent 5d51061 commit cf91518

File tree

2 files changed

+4
-21
lines changed

2 files changed

+4
-21
lines changed

setup.cfg

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,5 +41,3 @@ setup_requires =
4141

4242
[dist_conda]
4343
pythons = 3.6, 3.7, 3.8
44-
platforms = linux-64,win-32,win-64,osx-64
45-
force_conversion = True

setup.py

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,27 +8,12 @@
88
except ImportError:
99
CMDCLASS = {}
1010

11-
if "CONDA_BUILD" not in os.environ:
12-
dist = Distribution()
13-
dist.parse_config_files()
14-
INSTALL_REQUIRES = dist.install_requires
15-
else:
16-
INSTALL_REQUIRES = []
17-
18-
VERSION_SCHEME = {}
19-
VERSION_SCHEME["version_scheme"] = os.environ.get(
20-
"SCM_VERSION_SCHEME", "guess-next-dev"
21-
)
22-
VERSION_SCHEME["local_scheme"] = os.environ.get("SCM_LOCAL_SCHEME", "node-and-date")
23-
24-
VERSION_SCHEME = {}
25-
VERSION_SCHEME["version_scheme"] = os.environ.get(
26-
"SCM_VERSION_SCHEME", "release-branch-semver"
27-
)
28-
VERSION_SCHEME["local_scheme"] = os.environ.get("SCM_LOCAL_SCHEME", "node-and-date")
11+
VERSION_SCHEME = {
12+
"version_scheme": os.getenv("SCM_VERSION_SCHEME", "guess-next-dev"),
13+
"local_scheme": os.getenv("SCM_LOCAL_SCHEME", "node-and-date"),
14+
}
2915

3016
setup(
3117
use_scm_version=VERSION_SCHEME,
3218
cmdclass=CMDCLASS,
33-
install_requires=INSTALL_REQUIRES
3419
)

0 commit comments

Comments
 (0)