summaryrefslogtreecommitdiffstats
path: root/scripts/start.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/start.sh')
-rwxr-xr-xscripts/start.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/scripts/start.sh b/scripts/start.sh
new file mode 100755
index 0000000000..709a10265a
--- /dev/null
+++ b/scripts/start.sh
@@ -0,0 +1,15 @@
+#!/bin/sh -
+# Copyright 2014 The Gogs Authors. All rights reserved.
+# Use of this source code is governed by a MIT-style
+# license that can be found in the LICENSE file.
+#
+# start gogs web
+#
+IFS='
+ '
+PATH=/bin:/usr/bin:/usr/local/bin
+USER=$(whoami)
+HOME=$(grep "^$USER:" /etc/passwd | cut -d: -f6)
+export USER HOME PATH
+
+cd "$(dirname $0)" && exec ./gogs web