• 1 reply
  • Latest Post - ‏2012-11-27T16:34:31Z by brcowan
128 Posts

Pinned topic List the output of imcl in windows batch file

‏2012-11-26T22:32:16Z |
Hi All,

Could you please anyone update me how to store the output of "imcl listinstalledpackages" command in windows batch file variable?

Thanks in advance.

Updated on 2012-11-27T16:34:31Z at 2012-11-27T16:34:31Z by brcowan
  • brcowan
    739 Posts

    Re: List the output of imcl in windows batch file

    Given that that command output is a multi-line output, it may not be all that simple.

    For example:
    C:\Program Files (x86)\IBM\Installation Manager\eclipse\tools>imcl listinstalledpackages

    If the total length of the lines doesn't exceed the maximum command line length, you can try something like this:
    for %%x in ('"C:\Program Files (x86)\IBM\Installation Manager\eclipse\tools\imcl" listinstalledpackages') do set INS_PACK=%%x;%INS_PACK%

    Brian Cowan
    Advisory Software Engineer
    ClearCase Software Advisory Team (SWAT)
    Rational Software
    IBM Software Group
    550 King St
    Littleton, MA 01460

    Phone: 1.978.899.5436
    Updated on 2014-03-26T13:44:56Z at 2014-03-26T13:44:56Z by iron-man