full_path
stringlengths
31
232
filename
stringlengths
4
167
content
stringlengths
0
48.3M
PowerShellCorpus/PowerShellGallery/Rivet/0.8.1/Functions/Columns/New-NVarCharColumn.ps1
New-NVarCharColumn.ps1
function New-NVarCharColumn { <# .SYNOPSIS Creates a column object representing an NVarChar datatype. .DESCRIPTION Use this function in the `Column` script block for `Add-Table`: Add-Table -Name 'Albums' -Column { NVarChar 'Name' 50 } ## ALIASES ...
PowerShellCorpus/PowerShellGallery/Rivet/0.8.1/Functions/Columns/New-DecimalColumn.ps1
New-DecimalColumn.ps1
function New-DecimalColumn { <# .SYNOPSIS Creates a column object representing a `decimal` data type. .DESCRIPTION Use this function in the `Column` script block for `Add-Table`: Add-Table 'Items' { Decimal 'Price' } ## ALIASES * Decimal ...
PowerShellCorpus/PowerShellGallery/Rivet/0.8.1/Functions/Columns/New-SqlVariantColumn.ps1
New-SqlVariantColumn.ps1
function New-SqlVariantColumn { <# .SYNOPSIS Creates a column object representing an SqlVariant datatype. .DESCRIPTION Use this function in the `Column` script block for `Add-Table`: Add-Table 'WithSqlVariant' { SqlVariant 'ColumnName' } ## ALIASES ...
PowerShellCorpus/PowerShellGallery/Rivet/0.8.1/Functions/Columns/New-MoneyColumn.ps1
New-MoneyColumn.ps1
function New-MoneyColumn { <# .SYNOPSIS Creates a column object representing an Money datatype. .DESCRIPTION Use this function in the `Column` script block for `Add-Table`: Add-Table 'Items' { Money 'Price' } ## ALIASES * Money .EXAMPLE ...
PowerShellCorpus/PowerShellGallery/Rivet/0.8.1/Functions/Columns/New-Column.ps1
New-Column.ps1
function New-Column { <# .SYNOPSIS Creates a column object of an explicit datatype which can be used with the `Add-Table` or `Update-Table` migrations. .DESCRIPTION Use this function in the `Column` script block for `Add-Table`: Add-Table 'Members' { New-Column 'Birth...
PowerShellCorpus/PowerShellGallery/Rivet/0.8.1/Functions/Columns/New-DateTime2Column.ps1
New-DateTime2Column.ps1
function New-DateTime2Column { <# .SYNOPSIS Creates a column object representing an DateTime2 datatype. .DESCRIPTION Use this function in the `Column` script block for `Add-Table`: Add-Table 'Orders' { DateTime2 'OrderedAt' } ## ALIASES * DateT...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/3-1-TestData.ps1
3-1-TestData.ps1
@{ AllNodes = @( @{ NodeName = 'fourthcoffee81.cloudapp.net'; Role = 'Webserver'; } ) }
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/1-1-Configuration.Website.ps1
1-1-Configuration.Website.ps1
Configuration FourthCoffeeWebsite { param ( # Target nodes to apply the configuration [Parameter(Mandatory)] [ValidateNotNullOrEmpty()] [String[]]$NodeName, # Name of the website to create [Parameter(Mandatory)] [ValidateNotNullOrEmpty()] ...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/2-1-Configuration.Website.ps1
2-1-Configuration.Website.ps1
Configuration FourthCoffeeWebsite { param ( # Name of the website to create [Parameter(Mandatory)] [ValidateNotNullOrEmpty()] [String]$WebSiteName, # Source Path for Website content [Parameter(Mandatory)] [ValidateNotNullOrEmpty()] ...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/2-3-Invoke-Website-Local.ps1
2-3-Invoke-Website-Local.ps1
#region definitions $OutputPath = 'C:\TechEd-NA-2014\Demo\CompiledConfigurations' $SourcePath = 'C:\Content\TechEd-NA-2014\content\BakeryWebsite' $ScriptPath = 'C:\TechEd-NA-2014\Demo' $ConfigData = (& "$ScriptPath\2-2-DevData.ps1") #endregion definitions #region Compile configuration # Create the ...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/2-2-DevData.ps1
2-2-DevData.ps1
@{ AllNodes = @( @{ NodeName = 'Webserver-1'; Role = 'Webserver'; } ) }
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/3-2-Invoke-Website-Azure.ps1
3-2-Invoke-Website-Azure.ps1
#region definitions $ServiceName = 'fourthcoffee81' $OutputPath = 'C:\TechEd-NA-2014\Demo\CompiledConfigurations' $SourcePath = 'C:\Content\' Get-AzureWinRMUri -ServiceName $ServiceName -OutVariable WinRMUri $ScriptPath = 'C:\TechEd-NA-2014\Demo' $ConfigData = (& "$ScriptPath\3-1-TestData.ps1") #endr...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/1-3-Configuration-LCM.ps1
1-3-Configuration-LCM.ps1
configuration WebserverMetaconfig { param ( # Target nodes to apply the configuration [Parameter(Mandatory)] [ValidateNotNullOrEmpty()] [String[]]$NodeName ) # Import the module that defines custom resources Import-DscResource -Module xWebA...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/1-2-Invoke-Website.ps1
1-2-Invoke-Website.ps1
#region definitions $NodeName = 'Webserver-1' $OutputPath = 'C:\TechEd-NA-2014\Demo\CompiledConfigurations' $SourcePath = 'C:\Content\TechEd-NA-2014\content\BakeryWebsite' #endregion definitions #region Compile configuration # Create the MOF file using configuration parameters Remove-Item -Force ...
PowerShellCorpus/PowerShellGallery/nDemos_DCIM_B324/1.0/1-4-Invoke-AutoCorrect.ps1
1-4-Invoke-AutoCorrect.ps1
#region definitions $NodeName = 'Webserver-1' $OutputPath = 'C:\TechEd-NA-2014\Demo\CompiledConfigurations' #endregion definitions #region Compile configuration # Create the MOF file using configuration parameters Remove-Item -Force -Recurse $OutputPath WebserverMetaconfig -NodeName $NodeName -O...
PowerShellCorpus/PowerShellGallery/Fasdr/1.0.135/Fasdr.tests.ps1
Fasdr.tests.ps1
# # This is a PowerShell Unit Test file. # You need a unit test framework such as Pester to run PowerShell Unit tests. # You can download Pester from http://go.microsoft.com/fwlink/?LinkID=534084 # Get-Module Fasdr | Remove-Module Import-Module $PSScriptRoot\Fasdr.psm1 -ErrorAction Stop $testData = @" c:\dir1\dir2\tes...
PowerShellCorpus/PowerShellGallery/Fasdr/1.0.135/Fasdr.ArgumentCompleters.ps1
Fasdr.ArgumentCompleters.ps1
# # Fasdr.ArgumentCompleters.ps1 # function FasdrCompletion { param($commandName, $parameterName, $wordToComplete, $commandAst, $fakeBoundParameter) switch($commandName) { 'Set-Frecent' { $filterContainers = $false; $filterLeaves = $true} 'Set-FrecentFromLeaf' { $filterContainers = $true; $filterLeav...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Get-MimeType.ps1
Get-MimeType.ps1
function Get-MimeType { param( [Parameter(Mandatory=$true, ValueFromPipeline=$true, Position=0)] [ValidateScript({Test-Path $_})] [String]$File ) $res = 'application/unknown' try { $rk = [Microsoft.Win32.Registry]::ClassesRoot.OpenSubKey((([IO.FileInfo](($File = Convert-Path $File...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/New-MimeMessage.ps1
New-MimeMessage.ps1
function New-MimeMessage { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [string[]] $To, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [String] $From, [parameter(Mandatory=$true)] [Validate...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Convert-EpochToDate.ps1
Convert-EpochToDate.ps1
function Convert-EpochToDate { Param ( [parameter(Mandatory=$true,Position=0,ValueFromPipeline=$true)] [string] $EpochString ) $UnixEpoch = [timezone]::CurrentTimeZone.ToLocalTime([datetime]'1/1/1970') try { $result = $UnixEpoch.AddSeconds($EpochString) } catch ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Read-MimeMessage.ps1
Read-MimeMessage.ps1
function Read-MimeMessage { [cmdletbinding(DefaultParameterSetName="String")] Param ( [parameter(Mandatory=$true,Position=0,ValueFromPipeline=$true,ParameterSetName="String")] [ValidateNotNullOrEmpty()] [string[]] $String, [parameter(Mandatory=$true,Position=0,ValueFrom...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Convert-WebSafeBase64ToNormal.ps1
Convert-WebSafeBase64ToNormal.ps1
function Convert-WebSafeBase64ToNormal { Param ( [parameter(Mandatory=$true,Position=0)] [String] $WebSafeBase64String, [parameter(Mandatory=$false)] [String] $OutFile ) $WebSafeBase64String = $WebSafeBase64String.Replace('_', '/').Replace('-', '+').Replace('|',...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Convert-Base64.ps1
Convert-Base64.ps1
function Convert-Base64 { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [ValidateSet("NormalString","Base64String","WebSafeBase64String")] [ValidateScript({if($_ -eq $To){throw "The 'From' parameter must not be the same as the 'To' parameter"}else{$true}})] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/ConvertFrom-Base64String.ps1
ConvertFrom-Base64String.ps1
function ConvertFrom-Base64String { Param ( [parameter(Mandatory=$true,Position=0)] [String] $Base64String, [parameter(Mandatory=$false)] [switch] $FromWebSafeBase64, [parameter(Mandatory=$false)] [String] $OutFile ) if ($FromWebSafeBase64) ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Convert-KindToType.ps1
Convert-KindToType.ps1
function Convert-KindToType { Param ( [parameter(Mandatory=$true,Position=0,ValueFromPipeline=$true,ValueFromPipelineByPropertyName=$true)] [String] $Kind ) if ($Kind -like "*#*") { return "Google.$(($Kind -split "#" | ForEach-Object {$($_.substring(0,1).toupper()+$_.subst...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Private/Get-HTTPStatus.ps1
Get-HTTPStatus.ps1
function Get-HTTPStatus{ Param ( [parameter(Mandatory=$true)] [int] $Code ) $CodeHash=@{ 100="100 - Continue" 101="101 - Switching Protocols" 200="200 - OK" 201="201 - Created" 202="202 - Accepted" 203="203 - Non-Authoritative Information" 204="204 - No Content" 205=...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Clear-GSSheet.ps1
Clear-GSSheet.ps1
function Clear-GSSheet { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [String] $SpreadsheetId, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [string] $SpecifyRange, [parameter(Mandatory=$false)] [String] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSSheetValue.ps1
Update-GSSheetValue.ps1
function Update-GSSheetValue { [cmdletbinding(DefaultParameterSetName="CreateNewSheet")] Param ( [parameter(Mandatory=$true,Position=0,ParameterSetName="UseExisting")] [String] $SpreadsheetId, [parameter(Mandatory=$true,Position=0,ParameterSetName="CreateNewSheet")] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Import-GSSheet.ps1
Import-GSSheet.ps1
function Import-GSSheet { [cmdletbinding(DefaultParameterSetName="SheetsAPI")] Param ( [parameter(Mandatory=$true)] [String] $SpreadsheetId, [parameter(Mandatory=$false)] [String] $SheetName, [parameter(Mandatory=$false)] [ValidateNotNullOrEmp...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSGroup.ps1
New-GSGroup.ps1
function New-GSGroup { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $Email, [parameter(Mandatory=$true)] [String] $Name, [parameter(Mandatory=$false)] [String] $Description, [parameter(Mandatory=$false)] [Stri...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGroupList.ps1
Get-GSGroupList.ps1
function Get-GSGroupList { <# .Synopsis Gets the group list for a given account in Google Apps .DESCRIPTION Retrieves the full group list for the entire account .EXAMPLE Get-GSGroupList -AccessToken $(Get-GSToken @TokenParams) -MaxResults 5 -Where_IsAMember "random-user@domain.com" .EXAMPLE Get-GSG...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGmailLabelList.ps1
Get-GSGmailLabelList.ps1
function Get-GSGmailLabelList { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [string] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [switch] $Raw, [parameter(Mandatory=$false)] [String] $AccessToken, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSDriveFileList.ps1
Get-GSDriveFileList.ps1
function Get-GSDriveFileList { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [string] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [String[]] $Query, [parameter(Mandatory=$false)] [ValidateScript({[int]$_ ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Set-PSGSuiteDefaultDomain.ps1
Set-PSGSuiteDefaultDomain.ps1
function Set-PSGSuiteDefaultDomain { Param ( [parameter(Mandatory=$true,Position=0)] [ValidateNotNullOrEmpty()] [String] $Domain ) if ($Domain -ne $env:PSGSuiteDefaultDomain) { Write-Verbose "Setting default GSuite domain to '$Domain'" [Environment]::SetEnviron...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSDriveFile.ps1
Get-GSDriveFile.ps1
function Get-GSDriveFile { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $FileID, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-PSGSuiteConfig.ps1
Get-PSGSuiteConfig.ps1
Function Get-PSGSuiteConfig { <# .SYNOPSIS Gets PSGSuite module configuration. Based off of the PSGSuite Configuration functions found in that module: https://github.com/RamblingCookieMonster/PSGSuite .DESCRIPTION Get PSGSuite module configuration ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSTeamDrive.ps1
Remove-GSTeamDrive.ps1
function Remove-GSTeamDrive { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$true,Position=0)] [String] $TeamDriveID, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Start-PSGSuiteConfigWizard.ps1
Start-PSGSuiteConfigWizard.ps1
function Start-PSGSuiteConfigWizard { $inputXML = @" <Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="PSGSuite - Configuration Wizard" Height="398" Width="589" Background="White" WindowStartupLocation="C...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Set-PSGSuiteConfig.ps1
Set-PSGSuiteConfig.ps1
function Set-PSGSuiteConfig { <# .SYNOPSIS Sets PSGSuite module configuration. Based off of the PSSlack Configuration functions found in that module: https://github.com/RamblingCookieMonster/PSSlack .DESCRIPTION Set PSGSuite module configuration,...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSDataTransferApplicationList.ps1
Get-GSDataTransferApplicationList.ps1
function Get-GSDataTransferApplicationList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $CustomerID = $Script:PSGSuite.CustomerID, [parameter(Mandatory=$false)] [ValidateScript({[int]$_ -le 500 -and [int]$_ -ge 1})...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGroupMemberList.ps1
Get-GSGroupMemberList.ps1
function Get-GSGroupMemberList { <# .Synopsis Gets the group member list for a given group in Google Apps .DESCRIPTION Retrieves the full group list for the entire account .EXAMPLE Get-GSGroupMemberList -AccessToken $(Get-GSToken @TokenParams) -GroupEmail "my.group@domain.com" -MaxResults 10 .EXAMPLE ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGmailMessageInfo.ps1
Get-GSGmailMessageInfo.ps1
function Get-GSGmailMessageInfo { [cmdletbinding(DefaultParameterSetName="Format")] Param ( [parameter(Mandatory=$false)] [string] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$true,ValueFromPipelineByPropertyName=$True)] [Alias('id')] [String[]] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSUserASP.ps1
Remove-GSUserASP.ps1
function Remove-GSUserASP { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$false,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSUserSchema.ps1
Remove-GSUserSchema.ps1
function Remove-GSUserSchema { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String[]] $Schema, [parameter(Mandatory=$false)] [String] $CustomerID=$Script:PSGSuite.CustomerID, [parameter(Mandatory=$false)] [String] $AccessToken, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSCalendarResource.ps1
New-GSCalendarResource.ps1
function New-GSCalendarResource { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $ID, [parameter(Mandatory=$true)] [String] $Name, [parameter(Mandatory=$false)] [String] $Description, [parameter(Mandatory=$false)] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSGmailMessage.ps1
Remove-GSGmailMessage.ps1
function Remove-GSGmailMessage { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$true)] [String] $MessageID...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSUserSchema.ps1
New-GSUserSchema.ps1
function New-GSUserSchema { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $SchemaName, [parameter(Mandatory=$true)] [string[]] $FieldName, [parameter(Mandatory=$true)] [ValidateSet("BOOL","DATE","DOUBLE","EMAIL","INT64","PHONE","ST...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGmailDelegates.ps1
Get-GSGmailDelegates.ps1
ïŧŋfunction Get-GSGmailDelegates { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [Alias("Delegator")] [ValidateNotNullOrEmpty()] [String] $User = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSUserToken.ps1
Remove-GSUserToken.ps1
function Remove-GSUserToken { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$false,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUser.ps1
Get-GSUser.ps1
function Get-GSUser { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [ValidateNotNullOrEmpty()] [String] $User = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [ValidateSet("Basic","Custom","Full")] [string] $Projecti...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSDriveFileInfo.ps1
Get-GSDriveFileInfo.ps1
function Get-GSDriveFileInfo { [cmdletbinding(DefaultParameterSetName="Depth")] Param ( [parameter(Mandatory=$true,Position=0)] [String] $FileID, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:PSGSuite.AdminEmail, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Revoke-GSUserVerificationCodes.ps1
Revoke-GSUserVerificationCodes.ps1
function Revoke-GSUserVerificationCodes { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User, [parameter(Mandatory=$false)] [String] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Copy-GSDriveFile.ps1
Copy-GSDriveFile.ps1
function Copy-GSDriveFile { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $FileId, [parameter(Mandatory=$false)] [String] $Name, [parameter(Mandatory=$false)] [String] $Description, [parameter(Mandatory=$false)] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserASP.ps1
Get-GSUserASP.ps1
function Get-GSUserASP { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false,Position=1...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Restore-GSUser.ps1
Restore-GSUser.ps1
function Restore-GSUser { <# .Synopsis Restores a deleted Google user .DESCRIPTION Restores a deleted Google user .EXAMPLE Restore-GSUser -User john.smith@domain.com -OrgUnitPath "/Users/Rehires" -WhatIf .EXAMPLE Restore-GSUser -User john.smith@domain.com -OrgUnitPath "/Users/Rehires" -Confirm:$fal...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Add-GSGmailDelegate.ps1
Add-GSGmailDelegate.ps1
function Add-GSGmailDelegate { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [Alias("From","Delegator")] [ValidateNotNullOrEmpty()] [String] $User, [parameter(Mandatory=$true,Position=1)] [Alias("To")] [ValidateNotNullOrEmpty()] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSShortURL.ps1
New-GSShortURL.ps1
function New-GSShortURL { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [string] $LongURL, [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $P12KeyPath = $S...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSMobileDevice.ps1
Remove-GSMobileDevice.ps1
function Remove-GSMobileDevice { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$true,ValueFromPipelineByPropertyName=$true)] [ValidateNotNullOrEmpty()] [String] $ResourceID, [parameter(Mandatory=$false)] [ValidateN...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSUserSchema.ps1
Update-GSUserSchema.ps1
function Update-GSUserSchema { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $Schema, [parameter(Mandatory=$false)] [switch] $KeepExistingFields, [parameter(Mandatory=$true)] [string[]] $FieldName, [parameter(Mandator...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSOrganizationalUnit.ps1
New-GSOrganizationalUnit.ps1
function New-GSOrganizationalUnit { <# .Synopsis Creates a new Organizational Unit in Google Apps .DESCRIPTION Creates a new Organizational Unit in Google Apps. .EXAMPLE New-GSOrganizationalUnit -AccessToken $(Get-GSToken @TokenParams) -CustomerID $Customer -Name "Test Org" -ParentOrgUnitPath "/Testing"...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserList.ps1
Get-GSUserList.ps1
function Get-GSUserList { <# .Synopsis Gets the user list for a given account in Google Apps .DESCRIPTION Retrieves the full user list for the entire account. Accepts standard Google queries as a string or array of strings. .EXAMPLE Get-GSUserList -MaxResults 300 -Query "orgUnitPath=/Users","email=domai...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSCalendarResource.ps1
Update-GSCalendarResource.ps1
function Update-GSCalendarResource { [cmdletbinding()] Param ( [parameter(Mandatory=$true,ValueFromPipelineByPropertyName=$true)] [Alias("ID")] [String] $ResourceID, [parameter(Mandatory=$false)] [String] $Name, [parameter(Mandatory=$false)] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSUser.ps1
Remove-GSUser.ps1
function Remove-GSUser { <# .Synopsis Removes an existing Google user .DESCRIPTION Removes an existing Google user .EXAMPLE Remove-GSUser -User john.smith@domain.com -WhatIf .EXAMPLE Remove-GSUser -User john.smith@domain.com -Confirm:$false #> [cmdletbinding(SupportsShouldProcess=$true,Confir...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserPhoto.ps1
Get-GSUserPhoto.ps1
function Get-GSUserPhoto { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [String] $User, [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSDriveFile.ps1
Update-GSDriveFile.ps1
function Update-GSDriveFile { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $FileId, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [Stri...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSDriveFilePermissionsList.ps1
Get-GSDriveFilePermissionsList.ps1
function Get-GSDriveFilePermissionsList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [string] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$true)] [String] $FileID, [parameter(Mandatory=$false)] [ValidateSet("v2","v3")]...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Start-GSDataTransfer.ps1
Start-GSDataTransfer.ps1
function Start-GSDataTransfer { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [string] $OldOwnerUserId, [parameter(Mandatory=$true,Position=1)] [string] $NewOwnerUserId, [parameter(Mandatory=$true,Position=2,ValueFromPipelineByPropertyN...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSCalendarEventList.ps1
Get-GSCalendarEventList.ps1
function Get-GSCalendarEventList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [String] $CalendarID="primary", [parameter(Mandatory=$false)] [ValidateSet("StartTime","Updated")] [String] $OrderBy, [parameter(Mandatory=$false)] [Va...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSToken.ps1
Get-GSToken.ps1
function Get-GSToken { <# .Synopsis Gets a Service Account Access Token from Google Apps .DESCRIPTION Requests Access Token using Service Account and P12 key file, returns the token directly. Defaults to 3600 seconds token expiration time. .EXAMPLE $token = Get-GSToken -P12KeyPath "C:\PSGoogle.p12" -Sco...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSTeamDrivesList.ps1
Get-GSTeamDrivesList.ps1
function Get-GSTeamDrivesList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [string] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [ValidateScript({[int]$_ -le 100})] [Int] $PageSize="100", [parameter(Mandatory=$fal...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserVerificationCodes.ps1
Get-GSUserVerificationCodes.ps1
function Get-GSUserVerificationCodes { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$fa...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSShortURLList.ps1
Get-GSShortURLList.ps1
function Get-GSShortURLList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [ValidateSet("Full","Analytics_Clicks")] [string] $Projection="Full", [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [Va...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSOrganizationalUnit.ps1
Update-GSOrganizationalUnit.ps1
function Update-GSOrganizationalUnit { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0,ValueFromPipelineByPropertyName=$true,ValueFromPipeline=$true)] [ValidateNotNullOrEmpty()] [String] $OrgUnitID, [parameter(Mandatory=$false)] [String] $N...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Add-GSGmailFilter.ps1
Add-GSGmailFilter.ps1
function Add-GSGmailFilter { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [ValidateNotNullOrEmpty()] [string] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false,ValueFromPipelineByPropertyName=$true)] [string] $From, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Send-GmailMessage.ps1
Send-GmailMessage.ps1
function Send-GmailMessage { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $From=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$true)] [string] $Subject, [parameter(Mandatory=$true)] [string] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSCalendarResourceList.ps1
Get-GSCalendarResourceList.ps1
function Get-GSCalendarResourceList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [ValidateScript({[int]$_ -le 500})] [Int] $PageSize="500", [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [Valid...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSOrgUnitList.ps1
Get-GSOrgUnitList.ps1
function Get-GSOrgUnitList { <# .Synopsis Gets the OrgUnit list for a given account in Google Apps .DESCRIPTION Retrieves the full OrgUnit list for the entire account. Allows filtering by BaseOrgUnitPath (SearchBase) and Type (SearchScope) .EXAMPLE Get-GSOrgUnitList -AccessToken $(Get-GSToken @TokenPara...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSMobileDeviceList.ps1
Get-GSMobileDeviceList.ps1
function Get-GSMobileDeviceList { [cmdletbinding(DefaultParameterSetName="User")] Param ( [parameter(Mandatory=$false,ParameterSetName="User",Position=0)] [String] $User, [parameter(Mandatory=$false,ParameterSetName="Query",Position=0)] [String] $Query, [p...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSShortURLInfo.ps1
Get-GSShortURLInfo.ps1
function Get-GSShortURLInfo { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [string] $ShortURL, [parameter(Mandatory=$false)] [ValidateSet("Full","Analytics_Clicks","Analytics_Top_Strings")] [string] $Projection="Full", [parameter(Mandatory...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSGroupMember.ps1
Remove-GSGroupMember.ps1
function Remove-GSGroupMember { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String[]] $GroupEmail, [parameter(Mandatory=$true)] [Alias()] [String[]] $UserEmail, [parameter(Mandatory=$false)] [String] $AccessToken, [p...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Revoke-GSToken.ps1
Revoke-GSToken.ps1
function Revoke-GSToken { Param ( [parameter(Mandatory=$true)] [String[]] $AccessToken ) $total = $AccessToken.Length $i=0 foreach ($Token in $AccessToken) { $i++ try { Write-Verbose "Revoking token $i / $total - $Token" $response = Invoke-RestM...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSUser.ps1
Update-GSUser.ps1
function Update-GSUser { <# .Synopsis Updates an existing Google user .DESCRIPTION Updates an existing Google user .EXAMPLE Update-GSUser -User john.smith@domain.com -PrimaryEmail johnathan.smith@domain.com -GivenName Johnathan -Suspended False #> [cmdletbinding()] Param ( [parame...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Add-GSGroupMember.ps1
Add-GSGroupMember.ps1
function Add-GSGroupMember { [cmdletbinding()] Param ( [parameter(Position=0,Mandatory=$true)] [String[]] $GroupEmail, [parameter(Mandatory=$true,ValueFromPipeline=$true)] [String[]] $UserEmail, [parameter(Mandatory=$false)] [ValidateSet("MEMBER","M...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGmailMessageList.ps1
Get-GSGmailMessageList.ps1
function Get-GSGmailMessageList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [string] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [String[]] $LabelID, [parameter(Mandatory=$false)] [switch] $ExcludeChats, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSGmailFilter.ps1
Remove-GSGmailFilter.ps1
function Remove-GSGmailFilter { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$false,ValueFromPipelineByPropertyName=$true)] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$tru...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Add-GSDriveFilePermissions.ps1
Add-GSDriveFilePermissions.ps1
function Add-GSDriveFilePermissions { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [string] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$true)] [String] $FileID, [parameter(Mandatory=$false)] [String] $EmailAddress,...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSGroupSettings.ps1
Update-GSGroupSettings.ps1
function Update-GSGroupSettings { [cmdletbinding()] Param ( [parameter(Position=0,Mandatory=$true)] [String] $Group, [parameter(Mandatory=$false)] [String] $Name, [parameter(Mandatory=$false)] [String] $Description, [parameter(Mandator...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserASPList.ps1
Get-GSUserASPList.ps1
function Get-GSUserASPList { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserToken.ps1
Get-GSUserToken.ps1
function Get-GSUserToken { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$true,Positio...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Update-GSTeamDrive.ps1
Update-GSTeamDrive.ps1
function Update-GSTeamDrive { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [String] $TeamDriveID, [parameter(Mandatory=$false,Position=1)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mand...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGroup.ps1
Get-GSGroup.ps1
function Get-GSGroup { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [ValidateNotNullOrEmpty()] [String] $Group, [parameter(Mandatory=$false)] [String[]] $Fields, [parameter(Mandatory=$false)] [String] $AccessToken,...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Copy-GSSheet.ps1
Copy-GSSheet.ps1
function Copy-GSSheet { [cmdletbinding(DefaultParameterSetName="UseExisting")] Param ( [parameter(Mandatory=$true,Position=0)] [String] $SourceSpreadsheetId, [parameter(Mandatory=$true,Position=1)] [String] $SourceSheetId, [parameter(Mandatory=$true,...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserSchemaList.ps1
Get-GSUserSchemaList.ps1
function Get-GSUserSchemaList { [cmdletbinding()] Param ( [parameter(Mandatory=$false)] [String] $CustomerID=$Script:PSGSuite.CustomerID, [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Remove-GSGroup.ps1
Remove-GSGroup.ps1
function Remove-GSGroup { [cmdletbinding(SupportsShouldProcess=$true,ConfirmImpact="High")] Param ( [parameter(Mandatory=$true,Position=0)] [String] $Group, [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [Validate...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGroupSettings.ps1
Get-GSGroupSettings.ps1
function Get-GSGroupSettings { [cmdletbinding()] Param ( [parameter(Position=0,Mandatory=$true)] [String] $Group, [parameter(Mandatory=$false)] [String] $AccessToken, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $P...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSUserTokenList.ps1
Get-GSUserTokenList.ps1
function Get-GSUserTokenList { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0,ValueFromPipelineByPropertyName=$true)] [Alias("primaryEmail")] [ValidateNotNullOrEmpty()] [String] $User = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSTeamDrive.ps1
Get-GSTeamDrive.ps1
function Get-GSTeamDrive { [cmdletbinding()] Param ( [parameter(Mandatory=$true,Position=0)] [String] $TeamDriveID, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)]...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSDriveFile.ps1
New-GSDriveFile.ps1
function New-GSDriveFile { [cmdletbinding()] Param ( [parameter(Mandatory=$true)] [String] $Name, [parameter(Mandatory=$false)] [String[]] $ParentID, [parameter(Mandatory=$false)] [ValidateSet("Audio","Docs","Drawing","DriveFile","DriveFolder","Form...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/Get-GSGmailFilterList.ps1
Get-GSGmailFilterList.ps1
function Get-GSGmailFilterList { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [string] $User=$Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [switch] $Raw, [parameter(Mandatory=$false)] [String] $AccessToken, ...
PowerShellCorpus/PowerShellGallery/PSGSuite/1.2.1/Public/New-GSTeamDrive.ps1
New-GSTeamDrive.ps1
function New-GSTeamDrive { [cmdletbinding()] Param ( [parameter(Mandatory=$false,Position=0)] [ValidateNotNullOrEmpty()] [String] $Owner = $Script:PSGSuite.AdminEmail, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [String] $RequestID=$((N...