Functions/Remove-DatabricksClusterLibrariesFromWorkspaceByName.ps1

<#
.SYNOPSIS
Removes DataBricks Cluster Libraries from environment configuration
 
.DESCRIPTION
Removes DataBricks Cluster Libraries from environment configuration.
 
.PARAMETER config
Configuration json file from the environment.
 
.PARAMETER bearerToken
Your Databricks Bearer token to authenticate to your workspace (see User Settings in Datatbricks WebUI)
 
.PARAMETER librariesConfig
The name libraries config you want to remove/uninstall
The format has to be specified here: https://docs.microsoft.com/en-gb/azure/databricks/dev-tools/api/latest/libraries#--uninstall
 
.EXAMPLE
Remove-DatabricksClusterLibrariesFromWorkspaceByName -librariesConfig '<PSObject>'
 
.NOTES
Author: Sabin IO
 
#>
 
Function Remove-DatabricksClusterLibrariesFromWorkspaceByName {
    [cmdletbinding()]
    Param(
        [parameter(Mandatory = $true)]$librariesConfig
    )
    try {
        Remove-DatabricksLibrary -InputObject $librariesConfig   
    }    
    catch {
        #uh oh
        throw $_.Exception
    }
    return $results
}