當前位置: 首頁>>代碼示例>>Python>>正文


Python hardware.Hardware類代碼示例

本文整理匯總了Python中hardware.hardware.Hardware的典型用法代碼示例。如果您正苦於以下問題:Python Hardware類的具體用法?Python Hardware怎麽用?Python Hardware使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了Hardware類的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: post_install

    def post_install(self, dest_dir):
        """ Post install commands """
        # Add repos to user's pacman.conf
        path = os.path.join(dest_dir, "etc/pacman.conf")
        self.add_repositories(path)

        Hardware.chroot(["systemctl", "enable", "atieventsd"])
        Hardware.chroot(["systemctl", "enable", "catalyst-hook"])
        Hardware.chroot(["systemctl", "enable", "temp-links-catalyst"])

        Hardware.chroot(["aticonfig", "--initial"], dest_dir)
開發者ID:Antergos,項目名稱:Cnchi,代碼行數:11,代碼來源:catalyst_legacy.py

示例2: post_install

    def post_install(dest_dir):
        """ Post install commands """
        path = os.path.join(dest_dir, "etc/modules-load.d")
        os.makedirs(path, mode=0o755, exist_ok=True)
        path = os.path.join(dest_dir, "etc/modules-load.d/virtualbox-guest.conf")
        with open(path, 'w') as modules:
            modules.write('# Virtualbox modules added by Cnchi - Antergos Installer\n')
            modules.write("vboxguest\n")
            modules.write("vboxsf\n")
            modules.write("vboxvideo\n")

        Hardware.chroot(["systemctl", "disable", "openntpd"], dest_dir)
        Hardware.chroot(["systemctl", "-f", "enable", "vboxservice"], dest_dir)

        # This fixes bug in virtualbox-guest-modules package
        Hardware.chroot(["depmod", "-a"], dest_dir)
開發者ID:Antergos,項目名稱:Cnchi,代碼行數:16,代碼來源:virtualbox.py

示例3: __init__

 def __init__(self):
     Hardware.__init__(self, CLASS_NAME, CLASS_ID, VENDOR_ID, DEVICES)
開發者ID:codyzu,項目名稱:Cnchi,代碼行數:2,代碼來源:firewire.py

示例4: __init__

 def __init__(self):
     Hardware.__init__(self)
開發者ID:blinkythebear,項目名稱:Cnchi,代碼行數:2,代碼來源:modesetting.py

示例5: post_install

 def post_install(dest_dir):
     """ Post install commands """
     Hardware.chroot(["systemctl", "enable", "vmtoolsd"], dest_dir)
開發者ID:Antergos,項目名稱:Cnchi,代碼行數:3,代碼來源:vmware.py

示例6: __init__

 def __init__(self):
     Hardware.__init__(self, CLASS_NAME, CLASS_ID, VENDOR_ID, DEVICES, PRIORITY, ENABLED)
開發者ID:Antergos,項目名稱:Cnchi,代碼行數:2,代碼來源:catalyst_legacy.py


注:本文中的hardware.hardware.Hardware類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。