Skip to content

Commit

Permalink
add master branch deprecation notice
Browse files Browse the repository at this point in the history
  • Loading branch information
abn committed Feb 25, 2024
1 parent 8136c5f commit 500a313
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/poetry/console/application.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,18 @@ def _run(self, io: IO) -> int:
self._load_plugins(io)

exit_code: int = super()._run(io)

import os

if "PYTEST_CURRENT_TEST" not in os.environ:
io.write_line(
"<warning>"
"The Poetry project has renamed the <b>master</> branch to <b>main</>. The use of the <b>master</> "
"branch is now deprecated and the branch will be removed in the near future. Please update your refs "
"to use <b>main</> branch instead. Alternatively consider using released versions."
"</>"
)

return exit_code

def _configure_io(self, io: IO) -> None:
Expand Down

0 comments on commit 500a313

Please sign in to comment.