diff --git a/src/poetry/console/commands/env/activate.py b/src/poetry/console/commands/env/activate.py index dd70275ee52..5f0913fdfaa 100644 --- a/src/poetry/console/commands/env/activate.py +++ b/src/poetry/console/commands/env/activate.py @@ -44,7 +44,7 @@ def _get_activate_command(self, env: Env) -> str: command, filename = "source", "activate.fish" elif shell == "nu": command, filename = "overlay use", "activate.nu" - elif shell == "csh": + elif shell in ["csh", "tcsh"]: command, filename = "source", "activate.csh" elif shell in ["powershell", "pwsh"]: command, filename = ".", "Activate.ps1" diff --git a/tests/console/commands/env/test_activate.py b/tests/console/commands/env/test_activate.py index e4b9753e8f0..bea0e6df042 100644 --- a/tests/console/commands/env/test_activate.py +++ b/tests/console/commands/env/test_activate.py @@ -28,6 +28,7 @@ def tester(command_tester_factory: CommandTesterFactory) -> CommandTester: ("fish", "source", ".fish"), ("nu", "overlay use", ".nu"), ("csh", "source", ".csh"), + ("tcsh", "source", ".csh"), ), ) @pytest.mark.skipif(WINDOWS, reason="Only Unix shells")