MyTwitter.psm1
<#
=========================================================================== Created on: 8/31/2014 3:11 PM Created by: Adam Bertram Filename: MyTwitter.psm1 ------------------------------------------------------------------------- Module Name: MyTwitter Description: This Twitter module was built to give a Twitter user the ability to interact with Twitter via Powershell. Before importing this module, you must create your own Twitter application on apps.twitter.com and generate an access token under the API keys section of the application. Once you do so, I recommend copying/pasting your API key, API secret, access token and access token secret as default parameters under the Get-OAuthAuthorization function. =========================================================================== #> Set-StrictMode -Version Latest # Get public and private function definition files. $Public = @(Get-ChildItem -Path $PSScriptRoot\Public\*.ps1 -ErrorAction SilentlyContinue) $Private = @(Get-ChildItem -Path $PSScriptRoot\Private\*.ps1 -ErrorAction SilentlyContinue) # Dot source the files. foreach ($import in @($Public + $Private)) { try { Write-Verbose "Importing $($import.FullName)" . $import.FullName } catch { Write-Error "Failed to import function $($import.FullName): $_" } } foreach ($file in $Public) { Export-ModuleMember -Function $file.BaseName } |