home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / boot / i386 / root / usr / share / YaST2 / clients / ayast_probe.ycp < prev    next >
Text File  |  2006-11-29  |  3KB  |  63 lines

  1. /**
  2.  * File:        clients/ayast_probe.ycp
  3.  * Package:     Auto-installation
  4.  * Author:      Uwe Gansert <ug@suse.de>
  5.  * Summary:     This client is more or less for debugging.
  6.  *              It dumps interesting autoyast values and is
  7.  *              not as scaring as reading y2log just for some info
  8.  *
  9.  * Changes:     * initial - just dumps the rule values
  10.  * $Id: ayast_probe.ycp 27936 2006-02-13 20:01:14Z olh $
  11.  */
  12.  
  13. {
  14.     import "Stage";
  15.     Stage::Set( "initial" );
  16.     import "AutoInstallRules";
  17.     import "UI";
  18.     AutoInstallRules::ProbeRules();
  19.  
  20.     map<string,any> attrs = $[
  21.                             "installed_product":AutoInstallRules::installed_product,
  22.                             "installed_product_version":AutoInstallRules::installed_product_version,
  23.                             "hostname":AutoInstallRules::hostname,
  24.                             "hostaddress":AutoInstallRules::hostaddress,
  25.                             "network":AutoInstallRules::network,
  26.                             "domain":AutoInstallRules::domain,
  27.                             "arch":AutoInstallRules::arch,
  28.                             "karch":AutoInstallRules::karch,
  29.                             "product":AutoInstallRules::product,
  30.                             "product_vendor":AutoInstallRules::product_vendor,
  31.                             "board_vendor":AutoInstallRules::board_vendor,
  32.                             "board":AutoInstallRules::board,
  33.                             "memsize":AutoInstallRules::memsize,
  34.                             "totaldisk":AutoInstallRules::totaldisk,
  35.                             "hostid":AutoInstallRules::hostid,
  36.                             "mac":AutoInstallRules::mac,
  37.                             "linux":AutoInstallRules::linux,
  38.                             "others":AutoInstallRules::others,
  39.                             "xserver":AutoInstallRules::xserver,
  40.                             "haspcmcia":AutoInstallRules::haspcmcia,
  41. /*
  42.                             "NonLinuxPartitions":AutoInstallRules::NonLinuxPartitions,
  43.                             "LinuxPartitions":AutoInstallRules::LinuxPartitions,
  44.                             "disksize":AutoInstallRules::disksize
  45. */
  46.                            ];
  47.     string text="<h3>Keys for rules</h3><table>";
  48.     foreach( string k, any v, attrs, ``{
  49.         text = text + sformat("<tr><td>%1</td><td> = </td><td>%2<br></td></tr>",k,v);
  50.     });
  51.     text = text + "</table>";
  52.     UI::OpenDialog( `opt(`defaultsize),
  53.                 `VBox(
  54.                       `RichText( text ),
  55.                       `PushButton(`opt(`default), "&OK")
  56.                       )
  57.              );
  58.   UI::UserInput();
  59.   UI::CloseDialog();
  60. }
  61.  
  62.  
  63.