X-Git-Url: http://git.plutz.net/?p=busy;a=blobdiff_plain;f=actions%2Fprojectmeta.sh;h=1375e6c371e80cfa2ceb49856749b1e7260c438b;hp=ac7e454247aefda03f555a033991c464f681aafe;hb=HEAD;hpb=f485895094cd72318b46f39689c3ba954eb37411 diff --git a/actions/projectmeta.sh b/actions/projectmeta.sh index ac7e454..1375e6c 100755 --- a/actions/projectmeta.sh +++ b/actions/projectmeta.sh @@ -18,31 +18,31 @@ metafile="$_DATA/project.meta" -$ACL_ADMIN || echo "Location: //${HTTP_HOST}/?p=Error&i=noaccess\n\n" +$ACL_ADMIN || echo "Location: ?p=Error&i=noaccess\n\n" $ACL_ADMIN || exit 0 cgi_post -[ "$_POST[\"btcAdGamble\"]" = yes -a "$_POST[\"btcAdErotic\"]" = yes ] && btcAdContent=1 -[ "$_POST[\"btcAdGamble\"]" != yes -a "$_POST[\"btcAdErotic\"]" = yes ] && btcAdContent=2 -[ "$_POST[\"btcAdGamble\"]" = yes -a "$_POST[\"btcAdErotic\"]" != yes ] && btcAdContent=3 -[ "$_POST[\"btcAdGamble\"]" != yes -a "$_POST[\"btcAdErotic\"]" != yes ] && btcAdContent=4 +[ "${_POST[btcAdGamble]}" = yes -a "${_POST[btcAdErotic]}" = yes ] && btcAdContent=1 +[ "${_POST[btcAdGamble]}" != yes -a "${_POST[btcAdErotic]}" = yes ] && btcAdContent=2 +[ "${_POST[btcAdGamble]}" = yes -a "${_POST[btcAdErotic]}" != yes ] && btcAdContent=3 +[ "${_POST[btcAdGamble]}" != yes -a "${_POST[btcAdErotic]}" != yes ] && btcAdContent=4 echo -E "\ -name=$_POST[\"appName\"] -slogan=$_POST[\"appSlogan\"] -repoType=$(echo -E "$_POST[\"repoType\"]" |grep -Ex 'svn|git') -svnRepo=$_POST[\"svnRepo\"] -gitRepo=$_POST[\"gitRepo\"] -useFlattr=$(echo -E "$_POST[\"useFlattr\"]" |grep -Ex 'yes') -flattrThingURL=$_POST[\"flattrThingURL\"] -usePaypal=$(echo -E "$_POST[\"usePaypal\"]" |grep -Ex 'yes') -paypalAddress=$_POST[\"paypalAddress\"] -useBitcoin=$(echo -E "$_POST[\"useBitcoin\"]" |grep -Ex 'yes') -btcAddress=$_POST[\"btcAddress\"] -advertise=$(echo -E "$_POST[\"advertise\"]" |grep -Ex 'btcAd|no') -btcAdAddress=$_POST[\"btcAdAddress\"] -btcAdContent=$btcAdContent +name="${_POST[appName]}" +slogan="${_POST[appSlogan]}" +repoType=$(printf %s\\n "$_POST[\"repoType\"]" |grep -Ex 'svn|git') +svnRepo="${_POST[svnRepo]}" +gitRepo="${_POST[gitRepo]}" +useFlattr="$(printf %s\\n "${_POST[useFlattr]}" |grep -Ex 'yes')" +flattrThingURL="${_POST[flattrThingURL]}" +usePaypal="$(printf %s\\n "${_POST[usePaypal]}" |grep -Ex 'yes')" +paypalAddress="${_POST[paypalAddress]}" +useBitcoin="$(printf %s\\n "${_POST[useBitcoin]}" |grep -Ex 'yes')" +btcAddress="${_POST[btcAddress]}" +advertise="$(printf %s\\n "${_POST[advertise]}" |grep -Ex 'btcAd|no')" +btcAdAddress="${_POST[btcAdAddress]}" +btcAdContent="$btcAdContent" " >"$metafile" echo -n "Location: ${HTTP_REFERER}\n\n"