1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-11-16 06:03:44 +01:00
git/contrib/mw-to-git/t/install-wiki.sh
David Aguilar ebffb3d03c contrib/mw-to-git/t/install-wiki.sh: use a lowercase "usage:" string
Make the usage string consistent with Git.

Signed-off-by: David Aguilar <davvid@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-02-24 21:30:18 -08:00

45 lines
926 B
Bash
Executable file

#!/bin/sh
# This script installs or deletes a MediaWiki on your computer.
# It requires a web server with PHP and SQLite running. In addition, if you
# do not have MediaWiki sources on your computer, the option 'install'
# downloads them for you.
# Please set the CONFIGURATION VARIABLES in ./test-gitmw-lib.sh
WIKI_TEST_DIR=$(cd "$(dirname "$0")" && pwd)
if test -z "$WIKI_TEST_DIR"
then
WIKI_TEST_DIR=.
fi
. "$WIKI_TEST_DIR"/test-gitmw-lib.sh
usage () {
echo "usage: "
echo " ./install-wiki.sh <install | delete | --help>"
echo " install | -i : Install a wiki on your computer."
echo " delete | -d : Delete the wiki and all its pages and "
echo " content."
}
# Argument: install, delete, --help | -h
case "$1" in
"install" | "-i")
wiki_install
exit 0
;;
"delete" | "-d")
wiki_delete
exit 0
;;
"--help" | "-h")
usage
exit 0
;;
*)
echo "Invalid argument: $1"
usage
exit 1
;;
esac