PowerShell: override the prompt

This shows that once you go down a few folders deep, then there is very little command line real estate to type anything. Overriding the prompt function will give you a replacement until the end of the session (or you could of course just make it part of your PowerShell profile at startup).

So for me, a good compromise is to have the datetime – in fact I could just have the time.

function prompt {"$(&Get-Date)> "}

 

Mistakes and typos left in as usual:

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s