Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > PowerShell

Vista - Conversion tool

Reply
 
Old 12-21-2007   #1 (permalink)
DrewP


 
 

Conversion tool

Are there any tools available that convert .cmd scripts to powershell
scripts? I have found many vbscript tools but have had little sucess finding
a tool to convert my .cmd scripts. Any suggestions would be greatly
appreciated as my scripts are quite large and a tool would be super.

Thanks All,

-DrewP

My System SpecsSystem Spec
Old 12-21-2007   #2 (permalink)
Brandon Shell [MVP]


 
 

Re: Conversion tool

AFAIK there are none... it would be seriously complicated to write. You have
to make a ton of assumptions and it would be effectively useless IMO (meaning
it would fail badly.)

Conversion tools barely work on languages with constraints... with Batch
files you dont have any of those. For example you cannot do much with batch
files without external .exe files... how do you convert those?

Perhaps taking a functionized approach to the scripts you have would be best.

Brandon Shell
---------------
Blog: http://www.bsonposh.com/
PSH Scripts Project: www.codeplex.com/psobject

D> Are there any tools available that convert .cmd scripts to powershell
D> scripts? I have found many vbscript tools but have had little sucess
D> finding a tool to convert my .cmd scripts. Any suggestions would be
D> greatly appreciated as my scripts are quite large and a tool would be
D> super.
D>
D> Thanks All,
D>
D> -DrewP
D>


My System SpecsSystem Spec
Old 12-22-2007   #3 (permalink)
Gerd Schneider


 
 

RE: Conversion tool

I don't know of such a tool either and I hardly believe that it can be
written with reasonable effort. The main blocking point from my point of view
is "goto", which is the primary flow control statement of cmd and there is
absolutely no functional equivalent in ps.

Gerd

"DrewP" wrote:
Quote:

> Are there any tools available that convert .cmd scripts to powershell
> scripts? I have found many vbscript tools but have had little sucess finding
> a tool to convert my .cmd scripts. Any suggestions would be greatly
> appreciated as my scripts are quite large and a tool would be super.
>
> Thanks All,
>
> -DrewP
My System SpecsSystem Spec
Old 12-22-2007   #4 (permalink)
DrewP


 
 

RE: Conversion tool

Thanks for the info guys....Looks like I am going to be learning a ton of
powershell to convert my build scripts.

-DrewP

"DrewP" wrote:
Quote:

> Are there any tools available that convert .cmd scripts to powershell
> scripts? I have found many vbscript tools but have had little sucess finding
> a tool to convert my .cmd scripts. Any suggestions would be greatly
> appreciated as my scripts are quite large and a tool would be super.
>
> Thanks All,
>
> -DrewP
My System SpecsSystem Spec
Old 12-22-2007   #5 (permalink)
Keith Hill [MVP]


 
 

Re: Conversion tool

"DrewP" <DrewP@xxxxxx> wrote in message
news:5447C49F-D68F-41CD-ABF6-3380D801D476@xxxxxx
Quote:

> Thanks for the info guys....Looks like I am going to be learning a ton of
> powershell to convert my build scripts.
Been there and done that (except that I converted from Korn shell). The
resulting scripts are a lot easier to follow and more capable if you ask me.
:-)

--
Keith

My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
WAV to MP3 Conversion through VB.Net (3.5) .NET General
Win 7 conversion Live Mail
Conversion Vista General
VHS Conversion Vista hardware & devices


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46