A bit of background:
I use PowerShell on Windows XP at work, and I installed a bunch of useful shortcuts in Microsoft.PowerShell_profile.ps1in My Documents, trying to emulate a Mac environment inspired by Ryan Bates shortcuts
I have things like:
Set-Alias rsc Rails-Console
function Rails-Console {Invoke-Expression "ruby script/console"}
Which works fine when on the command line I say:
rsc
However, this does not work properly.
Set-Alias rsg Rails-Generate
function Rails-Generate {Invoke-Expression "ruby script/generate"}
So when I do this:
rsg model User
which should cause
ruby script/generate model User
everything that he causes
ruby script/generate
So, how to change my functions correctly to accept the parameters that I send to the functions?
Thank!
source
share