| Author |
Message |
Keith Hill
Guest
|
Posted:
Wed Nov 09, 2005 9:51 pm Post subject:
[MSH] remove-item |
|
|
I have been using MSH as my primary shell for a few days now and one thing that is driving me a bit batty is that I can't do this:
| Quote: | ri foo.cs bar.cs baz.cs
|
It tells me that a parameter cannot be found that matches parameter 'bar.cs'. Isn't there a way to build a cmdlet to behave like good old del or rm?
BTW, as long you are creating a bunch of item related aliases:
CommandType Name Definition
----------- ---- ----------
Alias ri remove-item
Alias si set-item
Alias ni new-item
Alias gi get-item
Alias ii invoke-item
Alias mi move-item
How about adding one for copy-item?
Alias ci copy-item
--
Keith |
|
| Back to top |
|
 |
Jouko Kynsijärvi
Guest
|
Posted:
Wed Nov 09, 2005 9:51 pm Post subject:
Re: [MSH] remove-item |
|
|
Keith Hill wrote:
| Quote: | I have been using MSH as my primary shell for a few days now and one
thing that is driving me a bit batty is that I can't do this:
ri foo.cs bar.cs baz.cs
It tells me that a parameter cannot be found that matches parameter
'bar.cs'. Isn't there a way to build a cmdlet to behave like good
old del or rm?
|
ri foo.cs,bar.cs,baz.cs
| Quote: | BTW, as long you are creating a bunch of item related aliases:
CommandType Name Definition
----------- ---- ----------
Alias ri remove-item
Alias si set-item
Alias ni new-item
Alias gi get-item
Alias ii invoke-item
Alias mi move-item
How about adding one for copy-item?
Alias ci copy-item
|
MSH> get-alias | where { $_.definition -like '*-item' }
....
Alias cpi copy-item
.... |
|
| Back to top |
|
 |
Keith Hill
Guest
|
Posted:
Thu Nov 10, 2005 1:51 am Post subject:
Re: [MSH] remove-item |
|
|
"Jouko Kynsijärvi" <jouko.kynsijarvi@nospam.nospam> wrote in message
news:e0E2LEX5FHA.3876@TK2MSFTNGP09.phx.gbl...
| Quote: | Keith Hill wrote:
I have been using MSH as my primary shell for a few days now and one
thing that is driving me a bit batty is that I can't do this:
ri foo.cs bar.cs baz.cs
It tells me that a parameter cannot be found that matches parameter
'bar.cs'. Isn't there a way to build a cmdlet to behave like good
old del or rm?
ri foo.cs,bar.cs,baz.cs
|
Cool, that'll work. Just put some spaces after the comma though so that
autocompletion still works. :-)
| Quote: | Alias cpi copy-item
|
It seems like the obvious choice for copy-item whould be "ci" but I see
there is both a clear-item (cli) and a copy-item (cpi). I would have still
gone with ci for copy-item. Oh well, that is easy enough to add to my
profile.
Thanks
Keith |
|
| Back to top |
|
 |
|
|
|
|