From b594708915ad4c2a1975860b9dc665eb98aa7d9a Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Wed, 22 May 2019 21:31:40 -0700 Subject: [PATCH] Vagrantfile: Be nicer to /etc/update-motd.d. Some of its information is helpful. Signed-off-by: Anders Kaseorg --- Vagrantfile | 17 +++++------------ tools/setup/dev-motd | 11 +++++++++++ 2 files changed, 16 insertions(+), 12 deletions(-) create mode 100755 tools/setup/dev-motd diff --git a/Vagrantfile b/Vagrantfile index 7a11b7535b..a8a38c3e77 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -176,18 +176,11 @@ set -o pipefail # development environment not using Vagrant. # Set the MOTD on the system to have Zulip instructions -sudo rm -f /etc/update-motd.d/* -sudo bash -c 'cat << EndOfMessage > /etc/motd -Welcome to the Zulip development environment! Popular commands: -* tools/provision - Update the development environment -* tools/run-dev.py - Run the development server -* tools/lint - Run the linter (quick and catches many problems) -* tools/test-* - Run tests (use --help to learn about options) - -Read https://zulip.readthedocs.io/en/latest/testing/testing.html to learn -how to run individual test suites so that you can get a fast debug cycle. - -EndOfMessage' +sudo ln -s /srv/zulip/tools/setup/dev-motd /etc/update-motd.d/99-zulip-dev +sudo rm -f /etc/update-motd.d/10-help-text +sudo dpkg --purge landscape-client landscape-common ubuntu-release-upgrader-core update-manager-core update-notifier-common +sudo dpkg-divert --add --rename /etc/default/motd-news +sudo sh -c 'echo ENABLED=0 > /etc/default/motd-news' # If the host is running SELinux remount the /sys/fs/selinux directory as read only, # needed for apt-get to work. diff --git a/tools/setup/dev-motd b/tools/setup/dev-motd new file mode 100755 index 0000000000..0e9e930ee0 --- /dev/null +++ b/tools/setup/dev-motd @@ -0,0 +1,11 @@ +#!/usr/bin/tail -n+2 + +This is the Zulip development environment. Popular commands: +* tools/provision - Update the development environment +* tools/run-dev.py - Run the development server +* tools/lint - Run the linter (quick and catches many problems) +* tools/test-* - Run tests (use --help to learn about options) + +Read https://zulip.readthedocs.io/en/latest/testing/testing.html to learn +how to run individual test suites so that you can get a fast debug cycle. +