3 if svn info >/dev/null 2>/dev/null; then
4 if [ "${4%%/*}" = "branches" ]; then
5 variant="LuCI ${4##*[-/]} Branch"
6 elif [ "${4%%/*}" = "tags" ]; then
7 variant="LuCI ${4##*[-/]} Release"
11 elif git status >/dev/null 2>/dev/null; then
12 tag="$(git describe --tags 2>/dev/null)"
13 branch="$(git symbolic-ref --short -q HEAD 2>/dev/null)"
15 if [ -n "$tag" ]; then
16 variant="LuCI $tag Release"
17 elif [ "$branch" != "master" ]; then
18 variant="LuCI ${branch##*-} Branch"
27 local pcall, dofile, _G = pcall, dofile, _G
31 if pcall(dofile, "/etc/openwrt_release") and _G.DISTRIB_DESCRIPTION then
33 distversion = _G.DISTRIB_DESCRIPTION
36 distversion = "Development Snapshot"
40 luciversion = "${2:-Git}"