[+] Powershell ls coloring
This commit is contained in:
+31
-1
@@ -1,7 +1,6 @@
|
|||||||
set-alias ll ls
|
set-alias ll ls
|
||||||
|
|
||||||
function su { powershell Start-Process powershell -Verb runAs }
|
function su { powershell Start-Process powershell -Verb runAs }
|
||||||
|
|
||||||
function pwdd { $("$PWD".replace($HOME, '~')) }
|
function pwdd { $("$PWD".replace($HOME, '~')) }
|
||||||
|
|
||||||
# Minecraft coloring
|
# Minecraft coloring
|
||||||
@@ -34,4 +33,35 @@ function prompt
|
|||||||
color ("&n" +
|
color ("&n" +
|
||||||
"&5$(get-date -UFormat "%a %m-%d %H:%M") &1Kevin-PC &eAzalea &r$(pwdd)&n" +
|
"&5$(get-date -UFormat "%a %m-%d %H:%M") &1Kevin-PC &eAzalea &r$(pwdd)&n" +
|
||||||
"> ")
|
"> ")
|
||||||
|
}
|
||||||
|
|
||||||
|
# ls coloring
|
||||||
|
Import-Module PSColor
|
||||||
|
$global:PSColor = @{
|
||||||
|
File = @{
|
||||||
|
Default = @{ Color = 'White' }
|
||||||
|
Directory = @{ Color = 'Blue'}
|
||||||
|
Hidden = @{ Color = 'DarkGray'; Pattern = '^\.' }
|
||||||
|
Code = @{ Color = 'Magenta'; Pattern = '\.(java|c|cpp|cs|js|css|html)$' }
|
||||||
|
Executable = @{ Color = 'Red'; Pattern = '\.(exe|bat|cmd|py|pl|ps1|psm1|vbs|rb|reg)$' }
|
||||||
|
Text = @{ Color = 'Yellow'; Pattern = '\.(txt|cfg|conf|ini|csv|log|config|xml|yml|md|markdown)$' }
|
||||||
|
Compressed = @{ Color = 'Green'; Pattern = '\.(zip|tar|gz|rar|jar|war)$' }
|
||||||
|
}
|
||||||
|
Service = @{
|
||||||
|
Default = @{ Color = 'White' }
|
||||||
|
Running = @{ Color = 'DarkGreen' }
|
||||||
|
Stopped = @{ Color = 'DarkRed' }
|
||||||
|
}
|
||||||
|
Match = @{
|
||||||
|
Default = @{ Color = 'White' }
|
||||||
|
Path = @{ Color = 'Cyan'}
|
||||||
|
LineNumber = @{ Color = 'Yellow' }
|
||||||
|
Line = @{ Color = 'White' }
|
||||||
|
}
|
||||||
|
NoMatch = @{
|
||||||
|
Default = @{ Color = 'White' }
|
||||||
|
Path = @{ Color = 'Cyan'}
|
||||||
|
LineNumber = @{ Color = 'Yellow' }
|
||||||
|
Line = @{ Color = 'White' }
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user