mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-11-25 09:23:12 +01:00
Improve the comment-based section
This commit is contained in:
parent
e85b2a5bd5
commit
d37e3ba990
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX MD5.ps1 [<file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION prints the MD5 checksum of the given file
|
MD5.ps1 [<file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Prints the MD5 checksum of the given file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\MD5.ps1 C:\MyFile.txt
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($File = "")
|
param($File = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX SHA1.ps1 [<file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION prints the SHA1 checksum of the given file
|
SHA1.ps1 [<file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Prints the SHA1 checksum of the given file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\SHA1.ps1 C:\MyFile.txt
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($File = "")
|
param($File = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX SHA256.ps1 [<file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION prints the SHA256 checksum of the given file
|
SHA256.ps1 [<file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Prints the SHA256 checksum of the given file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\SHA256.ps1 C:\MyFile.txt
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($File = "")
|
param($File = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-dropbox.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's Dropbox folder
|
cd-dropbox.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's Dropbox folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-dropbox.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME/Dropbox"
|
$TargetDir = resolve-path "$HOME/Dropbox"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-home.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's home folder
|
cd-home.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's home folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-home.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME"
|
$TargetDir = resolve-path "$HOME"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-music.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's music folder
|
cd-music.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's music folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-music.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME/Music"
|
$TargetDir = resolve-path "$HOME/Music"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-onedrive.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's OneDrive folder
|
cd-onedrive.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's OneDrive folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-onedrive.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME/OneDrive"
|
$TargetDir = resolve-path "$HOME/OneDrive"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-pics.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's pictures folder
|
cd-pics.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's pictures folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-pics.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME/Pictures"
|
$TargetDir = resolve-path "$HOME/Pictures"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-recycle-bin.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's recycle bin folder
|
cd-recycle-bin.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's recycle bin folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-recycle-bin.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
function Get-CurrentUserSID { [CmdletBinding()] param()
|
function Get-CurrentUserSID { [CmdletBinding()] param()
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-repos.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's Git repositories folder
|
cd-repos.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's Git repositories folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-repos.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME/Repos"
|
$TargetDir = resolve-path "$HOME/Repos"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-root.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the root directory (C: on Windows)
|
cd-root.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the root directory (C:\ on Windows)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-root.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
if ($IsLinux) {
|
if ($IsLinux) {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-scripts.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the PowerShell Scripts folder
|
cd-scripts.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the PowerShell Scripts folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-scripts.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$PSScriptRoot"
|
$TargetDir = resolve-path "$PSScriptRoot"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-up.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go one directory level up
|
cd-up.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go one directory level up
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-up.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path ".."
|
$TargetDir = resolve-path ".."
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-up2.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go two directory levels up
|
cd-up2.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go two directory levels up
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-up2.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "../.."
|
$TargetDir = resolve-path "../.."
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-up3.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go three directory levels up
|
cd-up3.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go three directory levels up
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-up3.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "../../.."
|
$TargetDir = resolve-path "../../.."
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-up4.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go four directory levels up
|
cd-up4.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go four directory levels up
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-up4.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "../../../.."
|
$TargetDir = resolve-path "../../../.."
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cd-videos.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION go to the user's videos folder
|
cd-videos.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Go to the user's videos folder
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cd-videos.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$TargetDir = resolve-path "$HOME/Videos"
|
$TargetDir = resolve-path "$HOME/Videos"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-cpu-temp.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the CPU temperature
|
check-cpu-temp.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the CPU temperature
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-cpu-temp.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-dns-resolution.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the DNS resolution with frequently used domain names
|
check-dns-resolution.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the DNS resolution with frequently used domain names
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-dns-resolution.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-drive-space.ps1 [<drive>] [<min-level>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the given drive for free space left
|
check-drive-space.ps1 [<drive>] [<min-level>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the given drive for free space left
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-drive-space.ps1 C
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Drive = "", [int]$MinLevel = 20) # minimum level in GB
|
param($Drive = "", [int]$MinLevel = 20) # minimum level in GB
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-file-system.ps1 [<drive>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the validity of the file system (needs admin rights)
|
check-file-system.ps1 [<drive>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the validity of the file system (needs admin rights)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-file-system.ps1 C
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -RunAsAdministrator
|
#Requires -RunAsAdministrator
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-health.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the health of the local computer
|
check-health.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the health of the local computer
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-health.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$Hostname = $(hostname)
|
$Hostname = $(hostname)
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-ipv4-address.ps1 [<address>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the given IPv4 address for validity
|
check-ipv4-address.ps1 [<address>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the given IPv4 address for validity
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-ipv4-address.ps1 192.168.11.22
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Address = "")
|
param($Address = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-ipv6-address.ps1 [<address>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the given IPv6 address for validity
|
check-ipv6-address.ps1 [<address>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the given IPv6 address for validity
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-ipv6-address.ps1 fe80::200:5aee:feaa:20a2
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Address = "")
|
param($Address = "")
|
||||||
|
@ -1,9 +1,15 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-mac-address.ps1 [<MAC>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the given MAC address for validity
|
check-mac-address.ps1 [<MAC>]
|
||||||
MAC address like 00:00:00:00:00:00 or 00-00-00-00-00-00 or 000000000000
|
.DESCRIPTION
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
Checks the given MAC address for validity
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
MAC address like 00:00:00:00:00:00 or 00-00-00-00-00-00 or 000000000000
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-mac-address.ps1 11:22:33:44:55:66
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($MAC = "")
|
param($MAC = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-ping.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the ping latency to the internet
|
check-ping.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the ping latency from the local computer to the internet
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-ping.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-swap-space.ps1 [<min-level>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the free swap space
|
check-swap-space.ps1 [<min-level>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the free swap space
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-swap-space.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param([int]$MinLevel = 50) # minimum level in GB
|
param([int]$MinLevel = 50) # minimum level in GB
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-symlinks.ps1 [<dir-tree>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks every symlink in the given directory tree
|
check-symlinks.ps1 [<dir-tree>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks every symlink in the given directory tree
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-symlinks.ps1 C:\MyApp
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($DirTree = "")
|
param($DirTree = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-weather.ps1 [<location>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the weather for critical values
|
check-weather.ps1 [<location>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the weather for critical values
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-weather.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Location = "") # empty means determine automatically
|
param($Location = "") # empty means determine automatically
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-windows-system-files.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the validity of the Windows system files (requires admin rights)
|
check-windows-system-files.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the validity of the Windows system files (requires admin rights)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-windows-system-files.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -RunAsAdministrator
|
#Requires -RunAsAdministrator
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX check-xml-file [<file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION checks the given XML file for validity
|
check-xml-file [<file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Checks the given XML file for validity
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\check-xml-file.ps1 myfile.xml
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($File = "")
|
param($File = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX cherry-picker.ps1 [<commit-id>] [<commit-message>] [<branches>] [<repo-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION cherry-picks a Git commit into multiple branches
|
cherry-picker.ps1 [<commit-id>] [<commit-message>] [<branches>] [<repo-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Cherry-picks a Git commit into multiple branches
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\cherry-picker.ps1 93849f889 "Fix typo" v1 v2 v3
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($CommitID = "", $CommitMessage = "", $Branches = "", $RepoDir = "$PWD")
|
param($CommitID = "", $CommitMessage = "", $Branches = "", $RepoDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX clean-repo.ps1 [<repo-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION cleans a Git repository from untracked files (including submodules, e.g. for a fresh build)
|
clean-repo.ps1 [<repo-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Cleans a Git repository from untracked files (including submodules, e.g. for a fresh build)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\clean-repo.ps1 C:\MyRepo
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($RepoDir = "$PWD")
|
param($RepoDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX clean-repos.ps1 [<parent-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION cleans all Git repositories under the current/given directory from untracked files (including submodules)
|
clean-repos.ps1 [<parent-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Cleans all Git repositories under the current/given directory from untracked files (including submodules)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\clean-repos.ps1 C:\MyRepos
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($ParentDir = "$PWD")
|
param($ParentDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX clear-recycle-bin.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION removes the content of the recycle bin folder (can not be undo!)
|
clear-recycle-bin.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Removes the content of the recycle bin folder (can not be undo!)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\clear-recycle-bin.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX clone-repos.ps1 [<parent-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION clones well-known Git repositories under the current/given directory.
|
clone-repos.ps1 [<parent-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Clones well-known Git repositories under the current/given directory.
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\clone-repos.ps1 C:\MyRepos
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($ParentDir = "$PWD")
|
param($ParentDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-calculator.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes the calculator program gracefully
|
close-calculator.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the calculator program gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-calculator.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "Calculator" "Calculator" "calc"
|
& "$PSScriptRoot/close-program.ps1" "Calculator" "Calculator" "calc"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-chrome.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes Google Chrome gracefully
|
close-chrome.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the Web browser Google Chrome gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-chrome.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "Google Chrome" "chrome" "chrome"
|
& "$PSScriptRoot/close-program.ps1" "Google Chrome" "chrome" "chrome"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-cortana.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes Cortana gracefully
|
close-cortana.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes Cortana gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-cortana.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "Cortana" "Cortana" "Cortana"
|
& "$PSScriptRoot/close-program.ps1" "Cortana" "Cortana" "Cortana"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-edge.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes Microsoft Edge gracefully
|
close-edge.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the Web browser Microsoft Edge gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-edge.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "Microsoft Edge" "msedge" "msedge"
|
& "$PSScriptRoot/close-program.ps1" "Microsoft Edge" "msedge" "msedge"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-file-explorer.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes Microsoft File Explorer gracefully
|
close-file-explorer.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes Microsoft File Explorer gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-file-explorer.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "File Explorer" "explorer" "explorer"
|
& "$PSScriptRoot/close-program.ps1" "File Explorer" "explorer" "explorer"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-program.ps1 [<full-program-name>] [<program-name>] [<program-alias-name>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes the processes of the given program gracefully
|
close-program.ps1 [<full-program-name>] [<program-name>] [<program-alias-name>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the processes of the given program gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-program.ps1 "Google Chrome" "chrome.exe"
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($FullProgramName = "", $ProgramName = "", $ProgramAliasName = "")
|
param($FullProgramName = "", $ProgramName = "", $ProgramAliasName = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-system-settings.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes the System Settings gracefully
|
close-system-settings.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the System Settings gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-system-settings.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "System Settings" "SystemSettings" "SystemSettings"
|
& "$PSScriptRoot/close-program.ps1" "System Settings" "SystemSettings" "SystemSettings"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-thunderbird.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes Mozilla Thunderbird gracefully
|
close-thunderbird.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the mail client Mozilla Thunderbird gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-thunderbird.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "Mozilla Thunderbird" "thunderbird" "thunderbird"
|
& "$PSScriptRoot/close-program.ps1" "Mozilla Thunderbird" "thunderbird" "thunderbird"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-vlc.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes the VLC media player gracefully
|
close-vlc.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes the VLC media player gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-vlc.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "VLC media player" "vlc" "vlc"
|
& "$PSScriptRoot/close-program.ps1" "VLC media player" "vlc" "vlc"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX close-windows-terminal.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION closes Windows Terminal gracefully
|
close-windows-terminal.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Closes Windows Terminal gracefully
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\close-windows-terminal.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
& "$PSScriptRoot/close-program.ps1" "Windows Terminal" "WindowsTerminal" "WindowsTerminal"
|
& "$PSScriptRoot/close-program.ps1" "Windows Terminal" "WindowsTerminal" "WindowsTerminal"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX configure-git.ps1 [<full-name>] [<email-address>] [<favorite-editor>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION sets up the Git user configuration
|
configure-git.ps1 [<full-name>] [<email-address>] [<favorite-editor>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Sets up the Git user configuration
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\configure-git.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($FullName = "", $EmailAddress = "", $FavoriteEditor = "")
|
param($FullName = "", $EmailAddress = "", $FavoriteEditor = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX convert-csv2txt.ps1 [<csv-file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION converts the given CSV file into a text list
|
convert-csv2txt.ps1 [<csv-file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Converts the given CSV file into a text list
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\convert-csv2txt.ps1 salaries.csv
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Path = "")
|
param($Path = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX convert-mysql2csv.ps1 [<server>] [<database>] [<username>] [<password>] [<query>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION convert the MySQL database table to a CSV file
|
convert-mysql2csv.ps1 [<server>] [<database>] [<username>] [<password>] [<query>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Convert the MySQL database table to a CSV file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\convert-mysql2csv.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX convert-ps2bat.ps1 [<pattern>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION converts PowerShell script(s) to .bat files
|
convert-ps2bat.ps1 [<pattern>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Converts PowerShell script(s) to .bat files
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\convert-ps2bat.ps1 *.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Pattern = "")
|
param($Pattern = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX convert-sql2csv.ps1 [<server>] [<database>] [<username>] [<password>] [<query>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION convert the SQL database table to a CSV file
|
convert-sql2csv.ps1 [<server>] [<database>] [<username>] [<password>] [<query>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Convert the SQL database table to a CSV file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\convert-sql2csv.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($server = "", $database = "", $username = "", $password = "", $query = "")
|
param($server = "", $database = "", $username = "", $password = "", $query = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX convert-txt2wav.ps1 [<text>] [<wav-file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION converts the given text to a .WAV audio file
|
convert-txt2wav.ps1 [<text>] [<wav-file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Converts the given text to a .WAV audio file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\convert-txt2wav.ps1 "Hello World" spoken.wav
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Text = "", $WavFile = "")
|
param($Text = "", $WavFile = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX create-branch.ps1 [<new-branch-name>] [<repo-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION creates and switches to a new branch in a Git repository
|
create-branch.ps1 [<new-branch-name>] [<repo-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Creates and switches to a new branch in a Git repository
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\create-branch.ps1 moonshot
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($NewBranchName = "", $RepoDir = "$PWD")
|
param($NewBranchName = "", $RepoDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX create-shortcut.ps1 [<shortcut>] [<target>] [<description>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION creates a new shortcut
|
create-shortcut.ps1 [<shortcut>] [<target>] [<description>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Creates a new shortcut file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\create-shortcut.ps1 C:\Temp\HDD C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Shortcut = "", $Target = "", $Description)
|
param($Shortcut = "", $Target = "", $Description)
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX create-symlink.ps1 [<symlink>] [<target>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION creates a symbolic link
|
create-symlink.ps1 [<symlink>] [<target>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Creates a symbolic link file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\create-symlink.ps1 C:\Temp\HDD C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Symlink = "", $Target = "")
|
param($Symlink = "", $Target = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX create-tag.ps1 [<new-tag-name>] [<repo-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION creates a new tag in the current/given Git repository
|
create-tag.ps1 [<new-tag-name>] [<repo-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Creates a new tag in the current/given Git repository
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\create-tag.ps1 v1.7
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($NewTagName = "", $RepoDir = "$PWD")
|
param($NewTagName = "", $RepoDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX decrypt-file.ps1 [<path>] [<password>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION decrypts the given file
|
decrypt-file.ps1 [<path>] [<password>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Decrypts the given file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\decrypt-file-rules.ps1 C:\MyFile.txt "123"
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param([string]$Path = "", [string]$Password = "")
|
param([string]$Path = "", [string]$Password = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX display-time.ps1 [<seconds>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION displays the current time for 10 seconds by default
|
display-time.ps1 [<seconds>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Displays the current time (for 10 seconds by default)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\display-time.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param([int]$Seconds = 10)
|
param([int]$Seconds = 10)
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX download-dir.ps1 [<URL>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION downloads a directory tree from the given URL
|
download-dir.ps1 [<URL>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Downloads a directory tree from the given URL
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\download-dir.ps1 "https://www.cnn.com"
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($URL = "")
|
param($URL = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX download-file.ps1 [<URL>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION downloads a file from the given URL
|
download-file.ps1 [<URL>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Downloads a file from the given URL
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\download-file.ps1 "https://www.cnn.com/index.html"
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($URL = "")
|
param($URL = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX edit.ps1 <filename>
|
.SYNOPSIS
|
||||||
.DESCRIPTION starts the built-in text editor to edit the given file
|
edit.ps1 <filename>
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Opens the built-in text editor to edit the given file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\edit.ps1 C:\MyFile.txt
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Filename = "")
|
param($Filename = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX enable-crash-dumps.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION enables the writing of crash dumps
|
enable-crash-dumps.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Enables the writing of crash dumps
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\enable-crash-dumps.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
##################################################################
|
##################################################################
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX enable-god-mode.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION enables the god mode (adds a new icon to the desktop)
|
enable-god-mode.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Enables the god mode (adds a new icon to the desktop)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\enable-god-mode.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX enable-ssh-client.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION enables the SSH client (needs admin rights)
|
enable-ssh-client.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Enables the SSH client (needs admin rights)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\enable-ssh-client.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -RunAsAdministrator
|
#Requires -RunAsAdministrator
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX enable-ssh-server.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION enables the SSH server (needs admin rights)
|
enable-ssh-server.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Enables the SSH server (needs admin rights)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\enable-ssh-server.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -RunAsAdministrator
|
#Requires -RunAsAdministrator
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX encrypt-file.ps1 [<path>] [<password>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION encrypts the given file
|
encrypt-file.ps1 [<path>] [<password>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Encrypts the given file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\encrypt-file.ps1 C:\MyFile.txt "123"
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Path = "", $Password = "")
|
param($Path = "", $Password = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX fetch-repo.ps1 [<repo-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION fetches updates for a local Git repository (including submodules)
|
fetch-repo.ps1 [<repo-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Fetches updates for a local Git repository (including submodules)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\fetch-repo.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($RepoDir = "$PWD")
|
param($RepoDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX fetch-repos.ps1 [<parent-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION fetches updates for all Git repositories under the current/given directory (including submodules)
|
fetch-repos.ps1 [<parent-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Fetches updates for all Git repositories under the current/given directory (including submodules)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\fetch-repos.ps1 C:\MyRepos
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($ParentDir = "$PWD")
|
param($ParentDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX generate-qrcode.ps1 [<text>] [<image-size>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION generates a QR code
|
generate-qrcode.ps1 [<text>] [<image-size>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Generates a QR code image file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\generate-qrcode.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Text = "", $ImageSize = "")
|
param($Text = "", $ImageSize = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX hibernate.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION enables hibernate mode for the local computer (needs admin rights)
|
hibernate.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Enables hibernate mode for the local computer (needs admin rights)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\hibernate.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -RunAsAdministrator
|
#Requires -RunAsAdministrator
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX inspect-exe.ps1 [<path-to-exe-file>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION prints basic information of the given executable file
|
inspect-exe.ps1 [<path-to-exe-file>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Prints basic information of the given executable file
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\inspect-exe.ps1 C:\MyApp.exe
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($PathToExe = "")
|
param($PathToExe = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX install-google-chrome.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION silently installs latest Google Chrome
|
install-google-chrome.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Silently installs latest Google Chrome
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\install-google-chrome.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX install-signal-cli.ps1 [<version>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION installs signal-cli from github.com/AsamK/signal-cli
|
install-signal-cli.ps1 [<version>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Installs signal-cli from github.com/AsamK/signal-cli. See the Web page for the correct version number.
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\install-signal-cli.ps1 0.11.12
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Version = "")
|
param($Version = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX introduce-powershell.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION introduces PowerShell to new users
|
introduce-powershell.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Introduces PowerShell to new users
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\introduce-powershell.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-aliases.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all PowerShell aliases
|
list-aliases.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all PowerShell aliases
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-aliases.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-anagrams.ps1 [<word>] [<columns>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all anagrams of the given word
|
list-anagrams.ps1 [<word>] [<columns>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all anagrams of the given word
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-anagrams.ps1 Markus
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Word = "", [int]$Columns = 8)
|
param($Word = "", [int]$Columns = 8)
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-automatic-variables.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the automatic variables of PowerShell
|
list-automatic-variables.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all automatic variables of PowerShell
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-auutomatic-variables.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
function AddItem { param([string]$Variable, [string]$Content)
|
function AddItem { param([string]$Variable, [string]$Content)
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-branches.ps1 [<repo-dir>] [<pattern>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all branches in the current/given Git repository
|
list-branches.ps1 [<repo-dir>] [<pattern>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all branches in the current/given Git repository
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-branches.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($RepoDir = "$PWD", $Pattern = "*")
|
param($RepoDir = "$PWD", $Pattern = "*")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-cheat-sheet.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the PowerShell cheat sheet
|
list-cheat-sheet.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the PowerShell cheat sheet
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-cheat-sheet.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
"PowerShell Cheat Sheet"
|
"PowerShell Cheat Sheet"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-city-weather.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION list the current weather of cities world-wide (west to east)
|
list-city-weather.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
List the current weather of cities world-wide (west to east)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-city-weather.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$Cities="Hawaii","Los Angeles","Mexico City","Miami","New York","Rio de Janeiro","Paris","London","Berlin","Cape Town","Dubai","Mumbai","Singapore","Hong Kong","Peking","Tokyo","Sydney"
|
$Cities="Hawaii","Los Angeles","Mexico City","Miami","New York","Rio de Janeiro","Paris","London","Berlin","Cape Town","Dubai","Mumbai","Singapore","Hong Kong","Peking","Tokyo","Sydney"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-clipboard.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the contents of the clipboard
|
list-clipboard.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the contents of the clipboard
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-clipboard.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-cmdlets.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all PowerShell cmdlets
|
list-cmdlets.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all PowerShell cmdlets
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-cmdlets.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-commits.ps1 [<repo-dir>] [<format>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all commits in the current/given Git repository
|
list-commits.ps1 [<repo-dir>] [<format>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all commits in the current/given Git repository
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-commits.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($RepoDir = "$PWD", $Format = "compact")
|
param($RepoDir = "$PWD", $Format = "compact")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-credits.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION shows the credits
|
list-credits.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Shows the credits for the PowerShell Scripts
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-credits.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-dir-tree.ps1 [<dir-tree>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists a directory tree
|
list-dir-tree.ps1 [<dir-tree>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the full directory tree
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-dir-tree.ps1 C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($DirTree = "$PWD")
|
param($DirTree = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-dir.ps1 [<pattern>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the directory content formatted in columns
|
list-dir.ps1 [<pattern>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the directory content formatted in columns
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-dir.ps1 C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($Pattern = "*")
|
param($Pattern = "*")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-drives.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all drives connected to the computer
|
list-drives.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all drives connected to the computer
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-drives.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-earthquakes.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists earthquakes with magnitude >= 6.0 for the last 30 days
|
list-earthquakes.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists earthquakes with magnitude >= 6.0 for the last 30 days
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-earthquakes.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
$Format="csv" # csv, geojson, kml, text, xml
|
$Format="csv" # csv, geojson, kml, text, xml
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-emojis.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the Emojis of Unicode 13.0
|
list-emojis.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the Emojis of Unicode 13.0
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-emojis.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
"Emojis of Unicode 13.0"
|
"Emojis of Unicode 13.0"
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-empty-dirs.ps1 [<dir-tree>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists empty subfolders within the given directory tree
|
list-empty-dirs.ps1 [<dir-tree>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists empty subfolders within the given directory tree
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-empty-dirs.ps1 C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($DirTree = "$PWD")
|
param($DirTree = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-empty-files.ps1 [<dir-tree>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists empty files within the given directory tree
|
list-empty-files.ps1 [<dir-tree>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists empty files within the given directory tree
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-empty-files.ps1 C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($DirTree = "")
|
param($DirTree = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-environment-variables.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all environment variables
|
list-environment-variables.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all environment variables
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-environment-variables.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-files.ps1 [<dir-tree>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists all files in the given directory tree
|
list-files.ps1 [<dir-tree>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all files in the given directory tree
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-files.ps1 C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($DirTree = "")
|
param($DirTree = "")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-fritzbox-calls.ps1 [<username>] [<password>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the phone calls of the FRITZ!Box device
|
list-fritzbox-calls.ps1 [<username>] [<password>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the phone calls of the FRITZ!Box device
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-fritzbox-calls.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -Version 3
|
#Requires -Version 3
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-fritzbox-calls.ps1 [<username>] [<password>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists FRITZ!Box's known devices
|
list-fritzbox-devices.ps1 [<username>] [<password>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists FRITZ!Box's known devices
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-fritzbox-devices.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
#Requires -Version 3
|
#Requires -Version 3
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-hidden-files.ps1 [<dir-tree>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists hidden files within the given directory tree
|
list-hidden-files.ps1 [<dir-tree>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists hidden files within the given directory tree
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-hidden-files.ps1 C:\
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($DirTree = "$PWD")
|
param($DirTree = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-installed-apps.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the installed Windows Store apps
|
list-installed-apps.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the installed Windows Store apps
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-installed-apps.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-installed-software.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the installed software (except Windows Store apps)
|
list-installed-software.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the installed software (except Windows Store apps)
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-installed-software.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-latest-tag.ps1 [<repo-dir>]
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the latest tag on the current branch in a Git repository
|
list-latest-tag.ps1 [<repo-dir>]
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists the latest tag on the current branch in a Git repository
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-latest-tag.ps1 C:\MyRepo
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
param($RepoDir = "$PWD")
|
param($RepoDir = "$PWD")
|
||||||
|
@ -1,8 +1,14 @@
|
|||||||
<#
|
<#
|
||||||
.SYNTAX list-memos.ps1
|
.SYNOPSIS
|
||||||
.DESCRIPTION lists the memos at $HOME/Memos.csv
|
list-memos.ps1
|
||||||
.LINK https://github.com/fleschutz/PowerShell
|
.DESCRIPTION
|
||||||
.NOTES Author: Markus Fleschutz / License: CC0
|
Lists all memos in $HOME/Memos.csv
|
||||||
|
.EXAMPLE
|
||||||
|
PS> .\list-memos.ps1
|
||||||
|
.LINK
|
||||||
|
https://github.com/fleschutz/PowerShell
|
||||||
|
.NOTES
|
||||||
|
Author: Markus Fleschutz / License: CC0
|
||||||
#>
|
#>
|
||||||
|
|
||||||
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user