mirror of
https://github.com/fleschutz/PowerShell.git
synced 2025-04-02 04:09:08 +02:00
Update my-profile.ps1
This commit is contained in:
parent
1b63f059be
commit
7e1e4f4336
@ -1,30 +1,22 @@
|
|||||||
# My PowerShell Profile
|
# My PowerShell Profile
|
||||||
# =====================
|
# =====================
|
||||||
# This file defines the look & feel of PowerShell - adapt the following lines to your needs, please.
|
# This profile file defines the look & feel of PowerShell.
|
||||||
|
|
||||||
|
# Window Title
|
||||||
# The Welcome Message
|
# ------------
|
||||||
# -------------------
|
|
||||||
"Welcome to PowerShell at $(hostname)'s 📂$(get-location)"
|
|
||||||
|
|
||||||
|
|
||||||
# The Window Title
|
|
||||||
# ----------------
|
|
||||||
if ($IsLinux) { $Username = $(whoami) } else { $Username = $env:USERNAME }
|
if ($IsLinux) { $Username = $(whoami) } else { $Username = $env:USERNAME }
|
||||||
$host.ui.RawUI.WindowTitle = "$Username @ $(hostname)"
|
$host.ui.RawUI.WindowTitle = "$Username @ $(hostname)"
|
||||||
|
|
||||||
|
|
||||||
# The Command Prompt
|
# Command Prompt
|
||||||
# ------------------
|
# --------------
|
||||||
function prompt { write-host -noNewline -foregroundColor yellow "`n➤"; return " " }
|
function prompt { write-host -noNewline -foregroundColor yellow "`n➤"; return " " }
|
||||||
|
|
||||||
|
|
||||||
# Supported Alias Names
|
# Alias Names
|
||||||
# ---------------------
|
# -----------
|
||||||
del alias:pwd -force -errorAction SilentlyContinue
|
del alias:pwd -force -errorAction SilentlyContinue
|
||||||
set-alias -name pwd -value list-workdir.ps1 # pwd = print working directory
|
set-alias -name pwd -value list-workdir.ps1 # pwd = print working directory
|
||||||
set-alias -name ll -value get-childitem # ll = list long
|
set-alias -name ll -value get-childitem # ll = list long
|
||||||
del alias:ls -force -errorAction SilentlyContinue
|
del alias:ls -force -errorAction SilentlyContinue
|
||||||
set-alias -name ls -value list-folder.ps1
|
set-alias -name ls -value list-folder.ps1
|
||||||
set-alias -name .. -value cd-up.ps1 # 1 dir level up
|
|
||||||
set-alias -name ... -value cd-up2.ps1 # 2 dir levels up
|
|
||||||
|
Loading…
Reference in New Issue
Block a user