Source

fabulator / src / fabulator / core / system / debian.py

Full commit
"""
    
"""

from fabric.api import run, sudo, cd

from base import BaseOs



class Debian(BaseOs):
    
    def install_packages(self, package_list=[]):
        packages = package_list or self.packages
        sudo("apt-get install %s" % " ".join(packages), False)
        
    def remove_packages(self, package_list=[]):
        packages = package_list or self.packages
        sudo("apt-get remove %s" % " ".join(packages), False)
        
    def update_packages(self, package_list=[]):
        packages = package_list or self.packages
        sudo("apt-get update %s" % " ".join(packages), False)
        
    def update_os(self):
        sudo("apt-get update", False)
        sudo("apt-get upgrade", False)
        sudo("apt-get dist-upgrade", False)