New commands + fixes

+ Get-Mount (mounts retuned as objects for easy filtering)
+ Get-RandomMacAddress (for easy MAC Address generation)
* Get-Path modified to resolve ~, also made it work with pipeline input
* Edit-TextFile streamlined by using modified Get-Path
* Added emacs and spacemacs to MyConfig
* dcup - attempt at cleaner output
+ added docker/profile.d/env.ps1 for default docker vars
This commit is contained in:
lksz 2021-02-18 10:53:32 -05:00
parent f947b0b3b4
commit f7df96c55d
7 changed files with 127 additions and 78 deletions

14
base.linux/Get-Mount.ps1 Normal file
View file

@ -0,0 +1,14 @@
[CmdletBinding()]param()
& mount |
ForEach-Object {
$null = $_ -match "^(.*) on (/.*) type ([^ ]*)( (.*))?$";
[PSCustomObject]([ordered]@{
Path = $matches[2]
Type = $matches[3]
Name = $matches[1]
Options = $matches[5]
# Matches = $Matches
# Raw = $_
})
}