Changes between Version 1 and Version 2 of YumCodeSnippet/GetArchInfo

Show
Ignore:
Author:
james (IP: 65.172.155.230)
Timestamp:
09/09/10 16:26:54 (7 years ago)
Comment:

Add the yum example.

Legend:

Unmodified
Added
Removed
Modified
  • YumCodeSnippet/GetArchInfo

    v1 v2  
    44import rpmUtils.arch 
    55 
     6# Directly... 
    67print '$arch =', rpmUtils.arch.getCanonArch() 
    78print '$basearch =', rpmUtils.arch.getBaseArch() 
     9 
     10import yum 
     11 
     12yb = yum.YumBase() 
     13# Via. yum 
     14print '$arch =', yb.arch.canonarch 
     15print '$basearch =', yb.arch.basearch 
     16 
    817}}}