balanced / bob

Bob the Builder - package your software into a deb/rpm/tar, publishes to a repository, and notifies you all by using a simple yaml file
https://balancedpayments.com/
5 stars 4 forks source link

Bob clobbers itself when it is using itself to build an upgraded debian file. #18

Open mahmoudimus opened 9 years ago

mahmoudimus commented 9 years ago

When bob is used to build bob, there is no going back if it fails to build. This is due to https://github.com/balanced/bob/blob/master/bob/builders/ubuntu/__init__.py#L81-L85

        for directory in (self.tmp_dir, self.target):
            self.run_command('sudo rm -rf {}'.format(directory))
            self.run_command('sudo mkdir -p {}'.format(directory))
            self.run_command('sudo chown {} {}'.format(
                getpass.getuser(), directory)
            )

Bob will blow away /opt/bob when it's trying to build the debian file.