PowerShell aliases, or how to run Notepad++ easily from PowerShell

I have to sometimes play around with PowerShell, and while in there, sometimes I need to edit files. I prefer Notepad++, but found it difficult and slow to start.

So aliases to the rescue. Just typing:

set-alias edit “C:\Program Files (x86)\Notepad++\notepad++.exe”

will create a new alias called edit. And it can be invoked with parameters too. So I can just type:

edit some.txt

and wherever I was, it now starts Notepad++. No need to modify path or anything.

Disclaimer: I am in no way associated with Notepad++, nor do I get anything from promoting them. I just happen to like that product very much! 🙂

You may also like...

2 Responses

  1. chandrika says:

    Thank you very much. It worked and saved a lot of time.

  2. Duck Dodgers says:

    Thans so much for this!

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: