Giter Site home page Giter Site logo

powershell's Introduction

PowerShell

My collection of useful functions, scripts, snippets and templates written by myself.

Description

Automate all the Things!

Module

How to install the module?

  1. Download the latest Release
  2. Copy the folder Module\LazyAdmin to C:\Users\%username%\Documents\WindowsPowerShell\Modules\
  3. Open up a PowerShell as an admin and set the execution policy: Set-ExecutionPolicy RemoteSigned
  4. Import the Module with the command Import-Module LazyAdmin (Maybe add this command to your PowerShell profile)

Available functions:

Folder: File

Function Description Help
Find-StringInFile Find a string in one or multiple files πŸ“–
Test-IsFileBinary Test if a file is binary πŸ“–
Update-StringInFile Replace a string in one or multiple files πŸ“–

Folder: Software

Function Description Help
Get-InstalledSoftware Get all installed software with DisplayName, Publisher and UninstallString πŸ“–

Folder: Network

Function Description Help
Clear-ARPCache Clear the ARP cache πŸ“–
Convert-IPv4Address Convert an IPv4-Address to Int64 and vise versa πŸ“–
Convert-Subnetmask Convert a subnetmask to CIDR and vise versa πŸ“–
Get-ARPCache Get the ARP cache πŸ“–
Get-IPv4Subnet Calculate a subnet based on an IP-Address and the subnetmask or CIDR πŸ“–
Get-MACAddress Get the MAC-Address from a remote computer πŸ“–
Get-MACVendor Get Vendor from a MAC-Address πŸ“–
Get-WLANProfile Get WLAN profiles, include password as SecureString or as plain text πŸ“–
Invoke-IPv4NetworkScan Powerful asynchronus IPv4 Network Scanner to scan an IP-Range or subnet πŸ“–
Invoke-IPv4PortScan Powerful asynchronus IPv4 Port Scanner to scan a TCP Port-Range πŸ“–
Send-WakeOnLan Send a network message to turn on or wake up a remote computer πŸ“–
Split-IPv4Subnet Split a subnet in multiple subnets with given subnetmasks πŸ“–

Folder: Security

Function Description Help
ConvertFrom-Base64 Convert a Base64 encoded string to a plain text string πŸ“–
ConvertTo-Base64 Convert a text (command) to an Base64 encoded string πŸ“–
Get-RandomPassword Generate passwords with a freely definable number of characters πŸ“–
Get-RandomPIN Generate PINs with freely definable number of numbers πŸ“–

Folder: TrustedHost

Function Description Help
Add-TrustedHost Add a trusted host (WinRM) πŸ“–
Get-TrustedHost Get trusted hosts (WinRM) πŸ“–
Remove-TrustedHost Remove a trusted host (WinRM) πŸ“–
Set-TrustedHost Set a trusted host (WinRM) πŸ“–

Folder: Windows

Function Description Help
Get-LastBootTime Get the time when a computer is booted πŸ“–
Get-WindowsProductKey Get the Windows product key and some usefull informations about the system πŸ“–

Folder: Other

Function Description Help
Get-ConsoleColor Get all available console colors πŸ“–

Scripts

Script Description Help
Convert-ROT13 Rotate lower and upper chars by n places (Caesar cipher) πŸ“–
Convert-ROT47 Rotate ascii chars by n places (Caesar cipher) πŸ“–
OptimizePowerShellStartup.ps1 Optimize PowerShell startup by reduce JIT compile time with ngen.exe πŸ“–

Snippets

Snippet Description
ConnectToExchange2010.ps1 Connect to Exchange 2010 Management Shell in script
CredentialParameter.ps1 Parameter to pass credentials into a function/script
DefaultDisplayPropertySet.ps1 Set the default properties of an object
New-Object.ps1 Create a new PSObject with custom properties
PressAnyKeyToContinue.ps1 Wait until the user pressed a key
PromptForChoice.ps1 Prompt for choice
PSCustomObject.ps1 Create a new PSObject with custom properties (faster than New-Object/Add-Member)
RewriteInLine.ps1 Rewrite in Line (Write-Host "xx% complete")
SelfElevatingScript.ps1 Self elevate a PowerShell script/console with parameters
Send-MailMessage.ps1 Send a mail message via PowerShell

Regex

Regex Description
IPv4Address.ps1 Validate an IPv4-Address like 192.168.1.0
MACAddress.ps1 Validate a MAC-Address like 00:00:00:00:00:00 or 00-00-00-00-00-00 or 000000000000
Subnetmask.ps1 Validate an Subnetmask like 255.255.255.0

Templates

Template Description
Default.ps1 Default template for new scripts
Default.README.md Default template for documentation on GitHub
RunspacePool.ps1 RunspacePool template - run code asynchron (faster than PSJobs)
ScheduledTask_Logging.ps1 Template to run a script as scheduled task with logging

powershell's People

Contributors

borntoberoot avatar mschaepers avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

powershell's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.