diff --git a/tools/paconn-cli/README.md b/tools/paconn-cli/README.md index 286a457e9..897060c2d 100644 --- a/tools/paconn-cli/README.md +++ b/tools/paconn-cli/README.md @@ -171,14 +171,15 @@ When environment or connector ID is not specified the command will prompt for th ``` Arguments - --cid -c : The custom connector ID. - --dest -d : Destination directory. - --env -e : Power Platform environment ID. - --pau -u : Power Platform URL. - --pav -v : Power Platform API version. - --settings -s : A settings file containing required parameters. - When a settings file is specified some command - line parameters are ignored. + --cid -c : The custom connector ID. + --dest -d : Destination directory. + --env -e : Power Platform environment ID. + --overwrite -w : Overwrite all the existing connector and settings files. + --pau -u : Power Platform URL. + --pav -v : Power Platform API version. + --settings -s : A settings file containing required parameters. + When a settings file is specified some command + line parameters are ignored. ``` ### Create a New Custom Connector diff --git a/tools/paconn-cli/paconn/operations/download.py b/tools/paconn-cli/paconn/operations/download.py index f23ca2481..4044732fc 100644 --- a/tools/paconn-cli/paconn/operations/download.py +++ b/tools/paconn-cli/paconn/operations/download.py @@ -47,12 +47,9 @@ def _prepare_directory(destination, connector_id): # Create a sub-directory in the current directory # when a destination isn't provided else: - if os.path.isdir(connector_id): - error = '{} directory already exists. Please remove the directory before continuing.' - raise CLIError(error.format(connector_id)) - else: + if not os.path.isdir(connector_id): os.mkdir(connector_id) - destination = connector_id + destination = connector_id if os.path.isdir(destination): os.chdir(destination)