Skip to content

Instantly share code, notes, and snippets.

View JonasNjopOlsson's full-sized avatar
🏠
Working from home

Jonas Olsson JonasNjopOlsson

🏠
Working from home
View GitHub Profile
@f-steff
f-steff / excel formulas.md
Last active June 28, 2024 08:01
Excel formulas to calculate IP values such as Netmask, IP range start, IP range end, Broadcast IP, Number of hosts.

Excel formulas to calculate IP values - Works in Excel and Google Sheet.

Updated 2023-12-11: Hosts calculation updated to support CIDR or 31 and 32.

Prerequisites:

  • A1 contains an IP address, such as 10.0.0.2
  • B1 contains the number of bits in the netmask (CIDR) such as 24

The below formulas then go into C1, D1 etc. to perform the various calculations. Some calculations depends on other calculations.

@jdhitsolutions
jdhitsolutions / Compare-Module.ps1
Last active July 31, 2023 21:33
Use this command to compare module versions between what is installed against an online repository like the PSGallery. Results will be automatically sorted by module name.
#requires -version 5.0
# https://gist.github.com/jdhitsolutions/7217ed9293f18e8d454e3f88ecb38b67
Function Compare-Module {
<#
.Synopsis
Compare module versions.
.Description
Use this command to compare module versions between what is installed against an online repository like the PSGallery. Results will be automatically sorted by module name.
@xcud
xcud / Get-Assemblies.ps1
Last active February 8, 2024 11:37
Gets a list of the assemblies loaded into memory in the current AppDomain.
<#
.Synopsis
Gets a list of the assemblies loaded into memory in the current AppDomain.
.Example
PS> Get-Assemblies power -NameOnly
Name
----
Microsoft.PowerShell.ConsoleHost.dll
Microsoft.PowerShell.Security.dll