Renamed killrails plugin to rails

This commit is contained in:
Nils Winkler
2016-05-23 08:39:18 +02:00
parent 5f35a6db38
commit 64a620d9e2

View File

@@ -0,0 +1,18 @@
cite about-plugin
about-plugin 'Function to kill a daemonized Rails server.'
# Quick function to kill a daemonized Rails server
function killrails() {
about 'Searches for a daemonized Rails server in tmp/pids and attempts to kill it.'
group 'killrails'
railsPid="$(cat tmp/pids/server.pid)"
if [ ! -z "$railsPid" ]; then
echo "[OK] Rails Server Process Id : ${railsPid}"
kill -9 $railsPid
echo "[OK] Process Killed"
else
echo "[FAIL] Error killing Rails server"
return 1
fi
}