Code review comment: Changed the exception type with 1d90337

Code under review:
public static void uninstallPackage(String fullPkgPath) {
        String orgName;
        String packageName;
        String version;
        
        int orgNameIndex = fullPkgPath.indexOf("/");
        if (orgNameIndex == -1) {
            throw new BLangCompilerException("no org-name is provided");
        }
        orgName = fullPkgPath.substring(0, orgNameIndex);

        
        int packageNameIndex = fullPkgPath.indexOf(":");
        if (packageNameIndex == -1) { 
            throw new BLangCompilerException("no package version is provided");
        }
        packageName = fullPkgPath.substring(orgNameIndex + 1, packageNameIndex);
        version = fullPkgPath.substring(packageNameIndex + 1, fullPkgPath.length());

        Path homeRepoPath = BALLERINA_HOME_PATH.resolve(ProjectDirConstants.DOT_BALLERINA_REPO_DIR_NAME);
        Path cacheRepoPath = BALLERINA_HOME_PATH.resolve(ProjectDirConstants.CACHES_DIR_NAME)
                                                .resolve(ProjectDirConstants.BALLERINA_CENTRAL_DIR_NAME);
        Path pkgPath = Paths.get(orgName, packageName, version);

        
        if (Files.exists(homeRepoPath.resolve(pkgPath), LinkOption.NOFOLLOW_LINKS)) {
            deletePackage(homeRepoPath, pkgPath, fullPkgPath, packageName);
        } else if (Files.exists(cacheRepoPath.resolve(pkgPath), LinkOption.NOFOLLOW_LINKS)) {
            deletePackage(cacheRepoPath, pkgPath, fullPkgPath, packageName);
        } else {
            
            throw new BLangCompilerException("package does not exist " + fullPkgPath);
        }
    }

Line commented on: throw new BLangCompilerException("no package version is provided");

Revised code:
public static void uninstallPackage(String fullPkgPath) {
        String orgName;
        String packageName;
        String version;
        
        int orgNameIndex = fullPkgPath.indexOf("/");
        if (orgNameIndex == -1) {
            throw LauncherUtils.createLauncherException("error: no org-name is provided");
        }
        orgName = fullPkgPath.substring(0, orgNameIndex);

        
        int packageNameIndex = fullPkgPath.indexOf(":");
        if (packageNameIndex == -1) { 
            throw LauncherUtils.createLauncherException("error: no package version is provided");
        }
        packageName = fullPkgPath.substring(orgNameIndex + 1, packageNameIndex);
        version = fullPkgPath.substring(packageNameIndex + 1, fullPkgPath.length());

        Path homeRepoPath = BALLERINA_HOME_PATH.resolve(ProjectDirConstants.DOT_BALLERINA_REPO_DIR_NAME);
        Path cacheRepoPath = BALLERINA_HOME_PATH.resolve(ProjectDirConstants.CACHES_DIR_NAME)
                                                .resolve(ProjectDirConstants.BALLERINA_CENTRAL_DIR_NAME);
        Path pkgDirPath = Paths.get(orgName, packageName, version);

        
        if (Files.exists(homeRepoPath.resolve(pkgDirPath), LinkOption.NOFOLLOW_LINKS)) {
            deletePackage(homeRepoPath, pkgDirPath, fullPkgPath, packageName);
        } else if (Files.exists(cacheRepoPath.resolve(pkgDirPath), LinkOption.NOFOLLOW_LINKS)) {
            deletePackage(cacheRepoPath, pkgDirPath, fullPkgPath, packageName);
        } else {
            
            throw LauncherUtils.createLauncherException("error: incorrect package signature provided " + fullPkgPath);
        }
    }