Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
-from datetime import datetime
+import subprocess
+
+from datetime import datetime
def compress(filename):
with open(filename, 'rb') as f_in:
with gzip.open('{}.gz'.format(filename), 'wb') as f_out:
shutil.copyfileobj(f_in, f_out)
def compress(filename):
with open(filename, 'rb') as f_in:
with gzip.open('{}.gz'.format(filename), 'wb') as f_out:
shutil.copyfileobj(f_in, f_out)