Skip to content

Commit

Permalink
!docs update
Browse files Browse the repository at this point in the history
  • Loading branch information
scrthq committed Sep 15, 2019
1 parent 1c0a48a commit 7b454e7
Show file tree
Hide file tree
Showing 22 changed files with 82 additions and 79 deletions.
3 changes: 3 additions & 0 deletions PSGSuite/Public/Authentication/Clear-PSGSuiteServiceCache.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ function Clear-PSGSuiteServiceCache {
.EXAMPLE
Clear-PSGSuiteServiceCache
.LINK
https://psgsuite.io/Function%20Help/Authentication/Clear-PSGSuiteServiceCache/
#>
[CmdletBinding()]
Param ()
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Authentication/Get-GSToken.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ function Get-GSToken {
Authorization = "Bearer $($Token)"
'GData-Version' = '3.0'
}
.LINK
https://psgsuite.io/Function%20Help/Authentication/Get-GSToken/
#>
Param (
[parameter(Mandatory = $true)]
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Authentication/Get-PSGSuiteServiceCache.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ function Get-PSGSuiteServiceCache {
.EXAMPLE
Get-PSGSuiteServiceCache
.LINK
https://psgsuite.io/Function%20Help/Authentication/Get-PSGSuiteServiceCache/
#>
[CmdletBinding()]
Param (
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Authentication/New-GoogleService.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ function New-GoogleService {
ServiceType = 'Google.Apis.Admin.Reports.reports_v1.ReportsService'
}
$service = New-GoogleService @serviceParams
.LINK
https://psgsuite.io/Function%20Help/Authentication/New-GoogleService/
#>
[CmdletBinding()]
Param(
Expand Down
6 changes: 6 additions & 0 deletions PSGSuite/Public/Calendar/Add-GSCalendarSubscription.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,12 @@ function Add-GSCalendarSubscription {
Add-GSCalendarSubscription -User me -CalendarId [email protected] -Selected -Color Cyan
Adds the calendar '[email protected]' to the AdminEmail user's calendar list
.LINK
https://psgsuite.io/Function%20Help/Calendar/Add-GSCalendarSubscription/
.LINK
https://developers.google.com/calendar/v3/reference/calendarList/insert
#>
[OutputType('Google.Apis.Calendar.v3.Data.CalendarListEntry')]
[cmdletbinding()]
Expand Down
15 changes: 12 additions & 3 deletions PSGSuite/Public/Calendar/Get-GSCalendar.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,15 @@ function Get-GSCalendar {
Get-GSCalendar
Gets the list of calendar subscriptions for the AdminEmail user.
.LINK
https://psgsuite.io/Function%20Help/Calendar/Get-GSCalendar/
.LINK
https://developers.google.com/calendar/v3/reference/calendarList/get
.LINK
https://developers.google.com/calendar/v3/reference/calendarList/list
#>
[OutputType('Google.Apis.Calendar.v3.Data.CalendarListEntry')]
[cmdletbinding(DefaultParameterSetName = "List")]
Expand Down Expand Up @@ -97,7 +106,7 @@ function Get-GSCalendar {
Get {
foreach ($calId in $CalendarId) {
try {
$request = $service.CalendarList.Get($calId)
$request = $service.Calendars.Get($calId)
Write-Verbose "Getting Calendar Id '$calId' for User '$U'"
$request.Execute() | Add-Member -MemberType NoteProperty -Name 'User' -Value $U -PassThru
}
Expand All @@ -113,7 +122,7 @@ function Get-GSCalendar {
}
List {
try {
$request = $service.CalendarList.List()
$request = $service.Calendars.List()
foreach ($key in $PSBoundParameters.Keys | Where-Object {$_ -ne 'CalendarId'}) {
if ($request.PSObject.Properties.Name -contains $key) {
$request.$key = $PSBoundParameters[$key]
Expand All @@ -124,7 +133,7 @@ function Get-GSCalendar {
$PageSize = $Limit
}
$request.MaxResults = $PageSize
Write-Verbose "Getting Calendar List for user '$U'"
Write-Verbose "Getting Calendars for user '$U'"
[int]$i = 1
$overLimit = $false
do {
Expand Down
9 changes: 9 additions & 0 deletions PSGSuite/Public/Calendar/Get-GSCalendarACL.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,15 @@ function Get-GSCalendarAcl {
Get-GSCalendarACL -User me -CalendarID "primary"
This gets the ACL on the primary calendar of the AdminUser.
.LINK
https://psgsuite.io/Function%20Help/Calendar/Get-GSCalendarACL/
.LINK
https://developers.google.com/calendar/v3/reference/acl/get
.LINK
https://developers.google.com/calendar/v3/reference/acl/list
#>
[OutputType('Google.Apis.Calendar.v3.Data.AclRule')]
[cmdletbinding(DefaultParameterSetName = 'List')]
Expand Down
9 changes: 9 additions & 0 deletions PSGSuite/Public/Calendar/Get-GSCalendarEvent.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,15 @@ function Get-GSCalendarEvent {
Get-GSCalendarEventList -TimeMin (Get-Date "01-21-2018 00:00:00") -TimeMax (Get-Date "01-28-2018 23:59:59") -SingleEvents
This gets the single events on the primary calendar of the Admin for the week of Jan 21-28, 2018.
.LINK
https://psgsuite.io/Function%20Help/Calendar/Get-GSCalendarEvent/
.LINK
https://developers.google.com/calendar/v3/reference/events/get
.LINK
https://developers.google.com/calendar/v3/reference/events/list
#>
[OutputType('Google.Apis.Calendar.v3.Data.Event')]
[cmdletbinding(DefaultParameterSetName = "List")]
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Calendar/Get-GSCalendarSubscription.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ function Get-GSCalendarSubscription {
Get-GSCalendarSubscription
Gets the AdminEmail user's calendar list
.LINK
https://psgsuite.io/Function%20Help/Calendar/Get-GSCalendarSubscription/
#>
[OutputType('Google.Apis.Calendar.v3.Data.CalendarListEntry')]
[cmdletbinding()]
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Calendar/New-GSCalendarACL.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ function New-GSCalendarAcl {
New-GSCalendarACL -CalendarID [email protected] -Role reader -Value [email protected] -Type user
Gives [email protected] reader access to jennyappleseed's calendar.
.LINK
https://psgsuite.io/Function%20Help/Calendar/New-GSCalendarACL/
#>
[OutputType('Google.Apis.Calendar.v3.Data.AclRule')]
[cmdletbinding(DefaultParameterSetName = "AttendeeEmails")]
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Calendar/New-GSCalendarEvent.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,9 @@ function New-GSCalendarEvent {
New-GSCalendarEvent "Go to the gym" -StartDate (Get-Date "21:00:00") -EndDate (Get-Date "22:00:00")
Creates an event titled "Go to the gym" for 9-10PM the day the function is ran.
.LINK
https://psgsuite.io/Function%20Help/Calendar/New-GSCalendarEvent/
#>
[OutputType('Google.Apis.Calendar.v3.Data.Event')]
[cmdletbinding(DefaultParameterSetName = "AttendeeEmails")]
Expand Down
7 changes: 5 additions & 2 deletions PSGSuite/Public/Calendar/Remove-GSCalendarAcl.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,14 @@ function Remove-GSCalendarAcl {
.EXAMPLE
Get-GSCalendar -User [email protected] |
Get-GSCalendarACL |
Get-GSCalendarAcl |
Where-Object {$_.Role -eq 'Owner'} |
Remove-GSCalendarACL
Remove-GSCalendarAcl
Gets all the calendars for Joe and finds all ACL rules where
.LINK
https://psgsuite.io/Function%20Help/Calendar/Remove-GSCalendarAcl/
#>
[CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "High")]
Param
Expand Down
3 changes: 3 additions & 0 deletions PSGSuite/Public/Calendar/Remove-GSCalendarEvent.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ function Remove-GSCalendarEvent {
Remove-GSCalendarEvent -User [email protected] -EventID _60q30c1g60o30e1i60o4ac1g60rj8gpl88rj2c1h84s34h9g60s30c1g60o30c1g84o3eg9n8gq32d246gq48d1g64o30c1g60o30c1g60o30c1g60o32c1g60o30c1g8csjihhi6oq3igi28h248ghk6ks4agq161144ga46gr4aci488p0
Removes the specified event from [email protected]'s calendar.
.LINK
https://psgsuite.io/Function%20Help/Calendar/Remove-GSCalendarEvent/
#>
[CmdletBinding(SupportsShouldProcess = $true, ConfirmImpact = "High")]
Param
Expand Down
13 changes: 8 additions & 5 deletions PSGSuite/Public/Calendar/Remove-GSCalendarSubscription.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,23 @@ function Remove-GSCalendarSubscription {
<#
.SYNOPSIS
Removes a calendar from a users calendar list (aka unsubscribes from the specified calendar)
.DESCRIPTION
Removes a calendar from a users calendar list (aka unsubscribes from the specified calendar)
.PARAMETER User
The primary email or UserID of the user. You can exclude the '@domain.com' to insert the Domain in the config or use the special 'me' to indicate the AdminEmail in the config.
.PARAMETER CalendarID
The calendar ID of the calendar you would like to unsubscribe the user from
.EXAMPLE
Remove-GSCalendarSubscription -User me -CalendarId [email protected]
Removes the calendar '[email protected]' from the AdminEmail user's calendar list
.LINK
https://psgsuite.io/Function%20Help/Calendar/Remove-GSCalendarSubscription/
#>
[cmdletbinding(SupportsShouldProcess = $true,ConfirmImpact = "High")]
Param
Expand Down Expand Up @@ -63,4 +66,4 @@ function Remove-GSCalendarSubscription {
}
}
}
}
}
16 changes: 1 addition & 15 deletions docs/Initial Setup.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,6 @@
# Initial Setup

* [Initial Setup](#initial-setup)
* [Prerequisites](#prerequisites)
* [Installing the Module](#installing-the-module)
* [From the PowerShell Gallery](#from-the-powershell-gallery)
* [From the GitHub release page](#from-the-github-release-page)
* [Build from the GitHub repo](#build-from-the-github-repo)
* [G Suite Users _with_ SuperAdmin access](#g-suite-users-with-superadmin-access)
* [Creating the Project, Service Account and P12 Key in Google's Developer Console](#creating-the-project-service-account-and-p12-key-in-googles-developer-console)
* [Adding API Client Access in Admin Console](#adding-api-client-access-in-admin-console)
* [Free Google Account Users and G Suite Users _without_ SuperAdmin access](#free-google-account-users-and-g-suite-users-without-superadmin-access)
* [Creating the Project and Client ID/Secret in Google's Developer Console](#creating-the-project-and-client-idsecret-in-googles-developer-console)
* [Creating the PSGSuite Configuration File](#creating-the-psgsuite-configuration-file)
* [First-time authentication for free/non-admin accounts](#first-time-authentication-for-freenon-admin-accounts)

***
Getting started with PSGSuite.

## Prerequisites
In order to use this module, you will need the following:
Expand Down
44 changes: 0 additions & 44 deletions docs/Managing Users.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,50 +2,6 @@

This section goes into detail on how to manage users, licenses and custom schemas using this module.

* [Managing Users](#managing-users)
* [User Management](#user-management)
* [Getting User Info](#getting-user-info)
* [Get-GSUser](#get-gsuser)
* [Getting User Photos](#getting-user-photos)
* [Get-GSUserPhoto](#get-gsuserphoto)
* [Listing Users](#listing-users)
* [Get-GSUserList](#get-gsuserlist)
* [Creating Users](#creating-users)
* [New-GSUser](#new-gsuser)
* [Updating Users](#updating-users)
* [Update-GSUser](#update-gsuser)
* [Removing Users](#removing-users)
* [Remove-GSUser](#remove-gsuser)
* [Restoring Users](#restoring-users)
* [Restore-GSUser](#restore-gsuser)
* [License Management](#license-management)
* [Getting License Info](#getting-license-info)
* [Get-GSLicenseInfo](#get-gslicenseinfo)
* [Listing Licenses](#listing-licenses)
* [Get-GSLicenseList](#get-gslicenselist)
* [Removing Licenses](#removing-licenses)
* [Remove-GSLicense](#remove-gslicense)
* [Setting Licenses](#setting-licenses)
* [Set-GSLicense](#set-gslicense)
* [Updating Licenses](#updating-licenses)
* [Update-GSLicense](#update-gslicense)
* [Custom Schema Management](#custom-schema-management)
* [Getting Custom Schema Info](#getting-custom-schema-info)
* [Get-GSUserSchemaInfo](#get-gsuserschemainfo)
* [Listing Custom Schemas](#listing-custom-schemas)
* [Get-GSUserSchemaList](#get-gsuserschemalist)
* [Creating Custom Schemas](#creating-custom-schemas)
* [New-GSUserSchema](#new-gsuserschema)
* [Removing Custom Schemas](#removing-custom-schemas)
* [Remove-GSUserSchema](#remove-gsuserschema)
* [Updating Custom Schemas](#updating-custom-schemas)
* [Update-GSUserSchema](#update-gsuserschema)

***


# User Management

## Getting User Info
### Get-GSUser
_This function pulls info for a specific user, including orgUnitPath, aliases, custom schema values, etc._
Expand Down
5 changes: 4 additions & 1 deletion docs/index.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
---
title: Home
---

# PSGSuite
<div align="center">
<img src="https://github.com/scrthq/PSGSuite/raw/master/bin/img/psgsuite2.0.0.png" alt="PSGSuite 2.0.0 released!" />
Expand Down Expand Up @@ -181,4 +185,3 @@ All other functions are either intact or have an alias included to support backw
* Updated Google .NET SDKs to latest versions.
* Updated and corrected a LOT of comment based function help.
* Added function help tests to validate that functions contain expected help content.

8 changes: 4 additions & 4 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ theme:
name: 'material'
language: 'en'
logo:
icon: 'cloud'
icon: 'arrow_forward_ios'
palette:
primary: 'indigo'
accent: 'indigo'
Expand All @@ -39,9 +39,9 @@ extra:
link: 'https://linkedin.com/in/scrthq'

# Google Analytics
#google_analytics:
# - 'UA-XXXXXXXX-X'
# - 'auto'
google_analytics:
- 'UA-101420411-4'
- 'auto'

# Extensions
markdown_extensions:
Expand Down
5 changes: 0 additions & 5 deletions psake.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -259,11 +259,6 @@ Task Docs -Depends Init {
$funcPath = Join-Path $docPath 'Function Help'
$docStage = Join-Path $PSScriptRoot 'docstage'
$sitePath = Join-Path $PSScriptRoot 'site'
<# " Importing module from path: $outputModDir"
$origPSModulePath = $env:PSModulePath
$env:PSModulePath = $env:BHBuildOutput + [System.IO.Path]::PathSeparator + $env:PSModulePath
#Import-Module $outputModDir -Force -Verbose
Import-Module $env:BHProjectName -Force -Verbose #>

" Setting index.md content from README"
Get-Content (Join-Path $PSScriptRoot 'README.md') -Raw | Set-Content (Join-Path $docPath 'index.md') -Force
Expand Down

0 comments on commit 7b454e7

Please sign in to comment.