Reference¶
poetry_up.console¶
Command-line interface.
-
poetry_up.console.
show_package
(package)¶ Print message describing the package upgrade.
- Return type
None
poetry_up.git¶
Git wrapper.
-
class
poetry_up.git.
MergeRequest
(title, description)¶ Merge request with a title and a description.
-
poetry_up.git.
add
(paths)¶ Add the specified paths to the index.
- Return type
None
-
poetry_up.git.
branch_exists
(branch)¶ Return True if the branch exists.
- Return type
bool
-
poetry_up.git.
commit
(message)¶ Create a commit using the given message.
- Return type
None
-
poetry_up.git.
current_branch
()¶ Return the checked out branch.
- Return type
str
-
poetry_up.git.
is_clean
(paths=())¶ Return True if the working tree, or the given files, are clean.
- Return type
bool
-
poetry_up.git.
push
(remote, branch, merge_request=None)¶ Push the branch to the remote.
- Parameters
remote (
str
) – The remote to push to.branch (
str
) – The branch to be pushed.merge_request (
Optional
[MergeRequest
]) – The merge request to create for the branch (optional).
- Return type
None
-
poetry_up.git.
remove_branch
(branch)¶ Remove the specified branch.
- Return type
None
-
poetry_up.git.
resolve_branch
(branch)¶ Return the SHA1 hash for the given branch.
- Return type
str
-
poetry_up.git.
switch
(branch, create=False, location=None)¶ Switch to the specified branch.
- Parameters
branch (
str
) – The branch to be switched to.create (
bool
) – Create the branch.location (
Optional
[str
]) – The location at which the branch should be created.
- Return type
None
poetry_up.github¶
GitHub wrapper.
-
poetry_up.github.
create_pull_request
(title, body)¶ Create a pull request for the checked out branch.
- Return type
None
-
poetry_up.github.
pull_request_exists
(branch)¶ Return True if a pull request exists for the given branch.
- Return type
bool
poetry_up.poetry¶
Poetry wrapper.
-
class
poetry_up.poetry.
Package
(name, old_version, new_version)¶ Package with current and available versions.
-
poetry_up.poetry.
update
(package, lock=False)¶ Update the given package.
- Parameters
package (
str
) – The package to be updated.lock (
bool
) – If True, do not install the package into the environment.
- Return type
None