-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathyoutube.psm1
27 lines (21 loc) · 844 Bytes
/
youtube.psm1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
try {
Import-Module -Name Pode -ErrorAction Stop
}
catch {
throw 'The YouTube module for PowerShell requires the Pode web server for completing the oAuth process.'
}
$script:RedirectUri = 'http://localhost:8000/auth/complete'
$script:Scopes = 'https://www.googleapis.com/auth/youtube https://www.googleapis.com/auth/youtube.readonly https://www.googleapis.com/auth/youtubepartner-channel-audit'
$script:ConfigPath = "$HOME/.pwsh.youtube.config.json"
$FileList = Get-ChildItem -Path $PSScriptRoot/functions/*ps1
foreach ($File in $FileList) {
. $File.FullName
}
$FileList = Get-ChildItem -Path $PSScriptRoot/functions/private/*ps1
foreach ($File in $FileList) {
. $File.FullName
}
$FormatList = Get-ChildItem -Path $PSScriptRoot/formats/*ps1xml
foreach ($Format in $FormatList) {
Update-FormatData -PrependPath $Format.FullName
}