From 1a61f2cd7c129e7eaf59c9b3716a408d6b332317 Mon Sep 17 00:00:00 2001 From: Sven Heidemann Date: Tue, 16 Mar 2021 23:00:22 +0100 Subject: [PATCH] Bugfixes in install command --- src/cpl_cli/command/install_service.py | 2 +- src/cpl_cli/command/update_service.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cpl_cli/command/install_service.py b/src/cpl_cli/command/install_service.py index 1e94a3dc..20bb7117 100644 --- a/src/cpl_cli/command/install_service.py +++ b/src/cpl_cli/command/install_service.py @@ -128,7 +128,7 @@ class InstallService(CommandABC): if not is_already_in_project: new_package = Pip.get_package(package) if new_package is not None: - new_package = package + new_package = name if '/' in new_package: new_package = new_package.split('/')[0] diff --git a/src/cpl_cli/command/update_service.py b/src/cpl_cli/command/update_service.py index ae7f6e64..de935006 100644 --- a/src/cpl_cli/command/update_service.py +++ b/src/cpl_cli/command/update_service.py @@ -107,8 +107,8 @@ class UpdateService(CommandABC): if '/' in new_package: new_package = new_package.split('/')[0] - if '\\' in new_package: - new_package = new_package.split('\\')[0] + if '\r' in new_package: + new_package = new_package.replace('\r', '') self._project_settings.dependencies[index] = new_package