X-Git-Url: https://us-delaporte.pagekite.me/gitweb/dotfiles.git/blobdiff_plain/221d984195390c9dc955082c1694e8e00db0c4fd..1dc756951cecfb1d0d8b33daba6955b0bcb3d0fc:/Microsoft.PowerShell_profile.ps1?ds=sidebyside diff --git a/Microsoft.PowerShell_profile.ps1 b/Microsoft.PowerShell_profile.ps1 index 5f667a0..7f54a1d 100644 --- a/Microsoft.PowerShell_profile.ps1 +++ b/Microsoft.PowerShell_profile.ps1 @@ -1,4 +1,11 @@ + +## Setup reminder: +# code $profile +# Set-ExecutionPolicy RemoteSigned +# . C:\src\dotfiles\Microsoft.PowerShell_profile.ps1 + + Import-Module posh-git # Courtesty of MKletz # Get-ChildItem -Path 'C:\Repos' -Filter "*.psd1" -Recurse | ForEach-Object -Process { @@ -21,6 +28,14 @@ $ENV:PATH+=";C:\Program Files\nodejs" # KataKoda wants to add tools via npm $ENV:PATH+=";C:\PENGUIN" # Flag to ensure my profile kicked in. +function Find-LargeFiles() { + Get-ChildItem c:\ -r| sort -descending -property length | select -first 10 name, Length, FullName +} + +function List-DriveSpace() { + Get-PSDrive C | Select-Object Used,Free +} + function Start-Vault() { consul agent -dev # Run in Dev Mode @@ -102,6 +117,11 @@ function Start-DockerFindSecrets { docker run -v /c/src:/etc/src dxa4481/trufflehog /etc/src/SecOps-Tools } +function Export-VSCodeExtensions { + code --list-extensions | Out-File -FilePath /src/dotfiles/vscode-extensions.txt + Get-Content -Path /src/dotfiles/vscode-extensions.txt +} + #requires -version 5.1 #ConvertTo-ASCIIArt.ps1 @@ -155,4 +175,15 @@ Function ConvertTo-ASCIIArt { End { Write-Verbose "[$((Get-Date).TimeofDay) END ] Ending $($myinvocation.mycommand)" } #end -} \ No newline at end of file +} + + +#### User Configuraable Variables #### +## https://github.com/techservicesillinois/Powershell-SupportApp + +# Customize the title bar of your console. +[string]$SA_title="PowerShell Support App for U of I" +# Path to a text editor +[string]$SA_TextEditor="C:\Program Files (x86)\Notepad++\notepad++.exe" +$SA_Config_base=$true +import-module .\PowerShellSupportAppV2\PowerShellSupportAppV2.psm1 \ No newline at end of file