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
544b4a14
Commit
544b4a14
authored
Oct 15, 2022
by
finswimmer
Committed by
Bjorn Neergaard
Nov 15, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(cli): added cli option to specify path to project to run on
parent
281b11a8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
1 deletions
+18
-1
src/poetry/console/application.py
+18
-1
No files found.
src/poetry/console/application.py
View file @
544b4a14
...
@@ -121,8 +121,13 @@ class Application(BaseApplication): # type: ignore[misc]
...
@@ -121,8 +121,13 @@ class Application(BaseApplication): # type: ignore[misc]
if
self
.
_poetry
is
not
None
:
if
self
.
_poetry
is
not
None
:
return
self
.
_poetry
return
self
.
_poetry
project_path
=
Path
.
cwd
()
if
self
.
_io
and
self
.
_io
.
input
.
option
(
"directory"
):
project_path
=
self
.
_io
.
input
.
option
(
"directory"
)
self
.
_poetry
=
Factory
()
.
create_poetry
(
self
.
_poetry
=
Factory
()
.
create_poetry
(
Path
.
cwd
()
,
cwd
=
project_path
,
io
=
self
.
_io
,
io
=
self
.
_io
,
disable_plugins
=
self
.
_disable_plugins
,
disable_plugins
=
self
.
_disable_plugins
,
disable_cache
=
self
.
_disable_cache
,
disable_cache
=
self
.
_disable_cache
,
...
@@ -367,6 +372,18 @@ class Application(BaseApplication): # type: ignore[misc]
...
@@ -367,6 +372,18 @@ class Application(BaseApplication): # type: ignore[misc]
)
)
)
)
definition
.
add_option
(
Option
(
"--directory"
,
"-C"
,
flag
=
False
,
description
=
(
"The working directory for the Poetry command (defaults to the"
" current working directory)."
),
)
)
return
definition
return
definition
def
_get_solution_provider_repository
(
self
)
->
SolutionProviderRepository
:
def
_get_solution_provider_repository
(
self
)
->
SolutionProviderRepository
:
...
...
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