Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
python-poetry
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
python-poetry
Commits
970193fb
Unverified
Commit
970193fb
authored
May 28, 2018
by
Sébastien Eustace
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add support for space-separated extras in commands
parent
783fb9a5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
2 deletions
+23
-2
poetry/console/commands/add.py
+7
-0
poetry/console/commands/debug/resolve.py
+8
-1
poetry/console/commands/install.py
+8
-1
No files found.
poetry/console/commands/add.py
View file @
970193fb
...
@@ -98,6 +98,13 @@ If you do not specify a version constraint, poetry will choose a suitable one ba
...
@@ -98,6 +98,13 @@ If you do not specify a version constraint, poetry will choose a suitable one ba
constraint
[
'allows-prereleases'
]
=
True
constraint
[
'allows-prereleases'
]
=
True
if
self
.
option
(
'extras'
):
if
self
.
option
(
'extras'
):
extras
=
[]
for
extra
in
self
.
option
(
'extras'
):
if
' '
in
extra
:
extras
+=
[
e
.
strip
()
for
e
in
extra
.
split
(
' '
)]
else
:
extras
.
append
(
extra
)
constraint
[
'extras'
]
=
self
.
option
(
'extras'
)
constraint
[
'extras'
]
=
self
.
option
(
'extras'
)
if
self
.
option
(
'python'
):
if
self
.
option
(
'python'
):
...
...
poetry/console/commands/debug/resolve.py
View file @
970193fb
...
@@ -41,7 +41,14 @@ class DebugResolveCommand(Command):
...
@@ -41,7 +41,14 @@ class DebugResolveCommand(Command):
dependencies
=
[]
dependencies
=
[]
for
name
,
constraint
in
requirements
.
items
():
for
name
,
constraint
in
requirements
.
items
():
dep
=
Dependency
(
name
,
constraint
)
dep
=
Dependency
(
name
,
constraint
)
for
ex
in
self
.
option
(
'extras'
):
extras
=
[]
for
extra
in
self
.
option
(
'extras'
):
if
' '
in
extra
:
extras
+=
[
e
.
strip
()
for
e
in
extra
.
split
(
' '
)]
else
:
extras
.
append
(
extra
)
for
ex
in
extras
:
dep
.
extras
.
append
(
ex
)
dep
.
extras
.
append
(
ex
)
dependencies
.
append
(
dep
)
dependencies
.
append
(
dep
)
...
...
poetry/console/commands/install.py
View file @
970193fb
...
@@ -36,7 +36,14 @@ exist it will look for <comment>pyproject.toml</> and do the same.
...
@@ -36,7 +36,14 @@ exist it will look for <comment>pyproject.toml</> and do the same.
self
.
poetry
.
pool
self
.
poetry
.
pool
)
)
installer
.
extras
(
self
.
option
(
'extras'
))
extras
=
[]
for
extra
in
self
.
option
(
'extras'
):
if
' '
in
extra
:
extras
+=
[
e
.
strip
()
for
e
in
extra
.
split
(
' '
)]
else
:
extras
.
append
(
extra
)
installer
.
extras
(
extras
)
installer
.
dev_mode
(
not
self
.
option
(
'no-dev'
))
installer
.
dev_mode
(
not
self
.
option
(
'no-dev'
))
installer
.
develop
(
self
.
option
(
'develop'
))
installer
.
develop
(
self
.
option
(
'develop'
))
installer
.
dry_run
(
self
.
option
(
'dry-run'
))
installer
.
dry_run
(
self
.
option
(
'dry-run'
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment