A set of PowerShell Cmdlets to interact with Carbon Black Cloud.
PS > git clone https://github.com/carbonblack/carbon-cli.git
PS > cd ./carbon-cli
PS > Import-Module ./CarbonCLI/CarbonCLI.psm1Now we can start using the cmdlets.
PS > Connect-CbcServer -Server "http://cbcserver.cbc" -Org "OrgKey" -Token "MyToken"Build the project:
PS > ./Build-CarbonCLI.ps1Install pre-commit
macOS:
$ brew install pre-commit
$ pre-commit installUsing pip:
$ pip install pre-commit
$ pre-commit installPS > ./Invoke-Tests.ps1If you want to check the test coverage for all of the files
Invoke-Pester -CodeCoverage ./CarbonCLI/Public/*or for specific file:
Invoke-Pester -CodeCoverage ./CarbonCLI/Public/Get-CbcDevice.ps1If you want to enable debug information
$DebugPreference = 'Continue'Please refer to this documentation: https://pester.dev/docs/usage/vscode