File tree Expand file tree Collapse file tree 3 files changed +21
-0
lines changed
Expand file tree Collapse file tree 3 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,10 @@ setup.py
2828 - automatically do git release while uploading to pypi
2929
30303. configured to build universial wheels by default
31+
32+ 4. comes with a feature of removing comments from requirements.txt while loading
33+ into setup.py
34+
3135{% endblock %}
3236
3337{% block bottom_block %}
Original file line number Diff line number Diff line change @@ -37,6 +37,10 @@ setup.py
3737
38383. configured to build universial wheels by default
3939
40+ 4. comes with a feature of removing comments from requirements.txt while loading
41+ into setup.py
42+
43+
4044Installation
4145================================================================================
4246
Original file line number Diff line number Diff line change @@ -113,7 +113,20 @@ if python_implementation == "PyPy":
113113INSTALL_REQUIRES = [
114114{% for dependency in dependencies: %}
115115 {% if ';' not in dependency and not dependency.startswith('#'): %}
116+ {% if '#egg=' in dependency: %}
117+ {% set dependency = dependency.split('#egg=') %}
118+ {% set repo_link, egg_name = dependency[0], dependency[1] %}
119+ {% set repo_link = repo_link.strip() %}
120+ {% if '#' in egg_name: %}
121+ {% set egg_name = egg_name.split('#')[0].strip() %}
122+ {% endif %}
123+ '{{[repo_link, egg_name] | join('#egg=')}}',
124+ {% elif '#' in dependency: %}
125+ {% set dependency = dependency.split('#')[0].strip() %}
126+ '{{dependency}}',
127+ {% else %}
116128 '{{dependency}}',
129+ {% endif %}
117130 {% endif %}
118131{% endfor %}
119132]
You can’t perform that action at this time.
0 commit comments