#!/bin/bash
  
motd_news_default="/etc/default/motd-news"
motd_news_cache="/var/cache/motd-news"

ubuntu_advantage_tools_cron="/etc/cron.daily/ubuntu-advantage-tools"
ubuntu_advantage_tools_cache="/var/cache/ubuntu-advantage-tools/ubuntu-advantage-status.cache"

if [ -f "${motd_news_default}" ];then
    sed -i 's/^ENABLED\s*=.*$/ENABLED=0/' "${motd_news_default}"
fi

if [ -f "${motd_news_cache}" ];then
    > ${motd_news_cache}
fi

if [ -f "${ubuntu_advantage_tools_cron}" ];then
    rm -f "${ubuntu_advantage_tools_cron}"
fi

if [ -f "${ubuntu_advantage_tools_cache}" ];then
    rm -f "${ubuntu_advantage_tools_cache}"
fi
