From 8d1b66accca613e0b79f075cda336c95be6bcf57 Mon Sep 17 00:00:00 2001 From: Marc Nause Date: Mon, 25 Aug 2014 22:47:33 +0200 Subject: [PATCH] Fix for http://mantis.tokeek.de/view.php?id=432 *) replaced all shebangs with more universal versions --- addon/thumbnail.sh | 2 +- addon/yacyInit.sh | 2 +- addon/yacyInit2.sh | 2 +- bin/addrss.sh | 2 +- bin/apicall.sh | 2 +- bin/apicat.sh | 2 +- bin/checkalive.sh | 2 +- bin/checkindex.sh | 2 +- bin/clearall.sh | 2 +- bin/clearapi.sh | 2 +- bin/clearcache.sh | 2 +- bin/clearindex.sh | 2 +- bin/deleteurl.sh | 2 +- bin/deploy.sh | 2 +- bin/down.sh | 2 +- bin/dumpcheck.sh | 2 +- bin/importOAIList.sh | 2 +- bin/importmediawiki.sh | 2 +- bin/importurllist.sh | 2 +- bin/indexdump.sh | 2 +- bin/indexrestore.sh | 2 +- bin/passwd.sh | 2 +- bin/search.sh | 2 +- bin/search1.sh | 2 +- bin/searchall.sh | 2 +- bin/searchtest.sh | 2 +- bin/searchtestmulti.sh | 2 +- bin/up.sh | 2 +- killYACY.sh | 2 +- reconfigureYACY.sh | 2 +- startYACY.sh | 2 +- stopYACY.sh | 2 +- updateYACY.sh | 2 +- 33 files changed, 33 insertions(+), 33 deletions(-) diff --git a/addon/thumbnail.sh b/addon/thumbnail.sh index ca6125716..d7aca8461 100755 --- a/addon/thumbnail.sh +++ b/addon/thumbnail.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh cd /tmp FILE=`tempfile`.html wget "$1" -O $FILE -k diff --git a/addon/yacyInit.sh b/addon/yacyInit.sh index c0f127752..ae2a0fdac 100755 --- a/addon/yacyInit.sh +++ b/addon/yacyInit.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh # # init script for the HTTP Proxy: YaCy # diff --git a/addon/yacyInit2.sh b/addon/yacyInit2.sh index af8ea9e6e..f6498830d 100755 --- a/addon/yacyInit2.sh +++ b/addon/yacyInit2.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh # # init script for the HTTP Proxy: YaCy # diff --git a/bin/addrss.sh b/bin/addrss.sh index e7438dc54..70209ef53 100755 --- a/bin/addrss.sh +++ b/bin/addrss.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/Load_RSS_p.html?indexAllItemContent=&repeat=off&url=$1" > /dev/null diff --git a/bin/apicall.sh b/bin/apicall.sh index c0951ad81..09400cbdb 100755 --- a/bin/apicall.sh +++ b/bin/apicall.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) admin=$(grep ^adminAccountUserName= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) diff --git a/bin/apicat.sh b/bin/apicat.sh index f361778ac..130892ae0 100755 --- a/bin/apicat.sh +++ b/bin/apicat.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) pw=$(grep ^adminAccountBase64MD5= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) diff --git a/bin/checkalive.sh b/bin/checkalive.sh index 07083bfe7..4ecda7b12 100755 --- a/bin/checkalive.sh +++ b/bin/checkalive.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" # for a production environment with high-availability requirement, diff --git a/bin/checkindex.sh b/bin/checkindex.sh index ef2bd3364..e8270bd4e 100755 --- a/bin/checkindex.sh +++ b/bin/checkindex.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`/.." for i in DATA/INDEX/* ; do if [ -d "$i" ]; then diff --git a/bin/clearall.sh b/bin/clearall.sh index ad977d7d2..f54923d33 100755 --- a/bin/clearall.sh +++ b/bin/clearall.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/IndexControlURLs_p.html?deletecomplete=&deleteIndex=on&deleteSolr=on&deleteCrawlQueues=on&deleteRobots=on&deleteSearchFl=on&deleteCache=on" > /dev/null \ No newline at end of file diff --git a/bin/clearapi.sh b/bin/clearapi.sh index 3b161a04d..fe3554e12 100755 --- a/bin/clearapi.sh +++ b/bin/clearapi.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/Tables_p.html?table=api&deletetable=all" > /dev/null \ No newline at end of file diff --git a/bin/clearcache.sh b/bin/clearcache.sh index 792f27c8d..84e63ff63 100755 --- a/bin/clearcache.sh +++ b/bin/clearcache.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/IndexControlURLs_p.html?deleteIndex=off&deleteSolr=off&deleteCache=on&deleteCrawlQueues=off&deleteRobots=on&deleteSearchFl=on&deletecomplete=" > /dev/null diff --git a/bin/clearindex.sh b/bin/clearindex.sh index f2cc02e38..2f4545aea 100755 --- a/bin/clearindex.sh +++ b/bin/clearindex.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/IndexControlURLs_p.html?deletecomplete=&deleteIndex=on&deleteSolr=on&deleteCrawlQueues=on&deleteRobots=on&deleteSearchFl=on&deleteCache=off" > /dev/null diff --git a/bin/deleteurl.sh b/bin/deleteurl.sh index 4820ac185..933e0d9fe 100755 --- a/bin/deleteurl.sh +++ b/bin/deleteurl.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/IndexControlURLs_p.html?urlhashdeleteall=&urlstring=$1" > /dev/null diff --git a/bin/deploy.sh b/bin/deploy.sh index ec430fc1c..4d3d6b10f 100755 --- a/bin/deploy.sh +++ b/bin/deploy.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" cd .. ./stopYACY.sh diff --git a/bin/down.sh b/bin/down.sh index 377169851..787351bfe 100755 --- a/bin/down.sh +++ b/bin/down.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) if which curl &>/dev/null; then diff --git a/bin/dumpcheck.sh b/bin/dumpcheck.sh index 5d4fda018..abb15fa04 100755 --- a/bin/dumpcheck.sh +++ b/bin/dumpcheck.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" java -ea -cp ../classes:../lib/yacycore.jar net.yacy.kelondro.logging.ThreadDump -f $1 diff --git a/bin/importOAIList.sh b/bin/importOAIList.sh index 98dc90944..add829386 100755 --- a/bin/importOAIList.sh +++ b/bin/importOAIList.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh cd "`dirname $0`" for N in `cat $1`; do echo import of $N: diff --git a/bin/importmediawiki.sh b/bin/importmediawiki.sh index fe83b5f2c..e30ace27b 100755 --- a/bin/importmediawiki.sh +++ b/bin/importmediawiki.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh /IndexImportMediawiki_p.html?file=$1 > /dev/null diff --git a/bin/importurllist.sh b/bin/importurllist.sh index ce943f7e4..29d46ba60 100755 --- a/bin/importurllist.sh +++ b/bin/importurllist.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/Crawler_p.html?bookmarkFolder=/crawlStart&crawlingDomMaxPages=10000&intention=&range=domain&indexMedia=on&recrawl=nodoubles&storeHTCache=on&sitemapURL=&repeat_time=7&crawlingQ=on&crawlingIfOlderUnit=day&cachePolicy=ifexist&indexText=on&crawlingMode=file&crawlingURL=http://&bookmarkTitle=&mustnotmatch=&crawlingstart=import&mustmatch=.*&crawlingIfOlderNumber=7&repeat_unit=seldays&crawlingDepth=0&crawlingFile=$1" > /dev/null diff --git a/bin/indexdump.sh b/bin/indexdump.sh index e2d694f59..dc18d0d58 100755 --- a/bin/indexdump.sh +++ b/bin/indexdump.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/IndexControlURLs_p.xml?indexdump=" | awk '//{ gsub("","" );gsub("<\/dumpfile>","" ); print $0 }' | awk '{print $1}'; \ No newline at end of file diff --git a/bin/indexrestore.sh b/bin/indexrestore.sh index 61134db87..9ecdb8a92 100755 --- a/bin/indexrestore.sh +++ b/bin/indexrestore.sh @@ -1,3 +1,3 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/IndexControlURLs_p.xml?indexrestore=&dumpfile=$1" > /dev/null diff --git a/bin/passwd.sh b/bin/passwd.sh index f2b61bc60..172f06006 100755 --- a/bin/passwd.sh +++ b/bin/passwd.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/ConfigAccounts_p.html?setAdmin=&adminuser=admin&adminpw1=$1&adminpw2=$1&access=" > /dev/null echo "Password for User Name 'admin' set to '$1'" \ No newline at end of file diff --git a/bin/search.sh b/bin/search.sh index 5f68dfbb5..f8e6e12fd 100755 --- a/bin/search.sh +++ b/bin/search.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) ./search1.sh -y localhost:$port "$1" \ No newline at end of file diff --git a/bin/search1.sh b/bin/search1.sh index c66ba5ed3..b679e8e65 100755 --- a/bin/search1.sh +++ b/bin/search1.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" if which curl &>/dev/null; then while getopts "ys" opt; do diff --git a/bin/searchall.sh b/bin/searchall.sh index 39ef07c3c..31c56282e 100755 --- a/bin/searchall.sh +++ b/bin/searchall.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" port=$(grep ^port= ../DATA/SETTINGS/yacy.conf |cut -d= -f2) ./searchall1.sh -s localhost:$port $1 \ No newline at end of file diff --git a/bin/searchtest.sh b/bin/searchtest.sh index eea86e7d6..a60495932 100755 --- a/bin/searchtest.sh +++ b/bin/searchtest.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh cd "`dirname $0`" S=`date "+%s"` C=0 diff --git a/bin/searchtestmulti.sh b/bin/searchtestmulti.sh index bc2a18e53..b31fb4e3a 100755 --- a/bin/searchtestmulti.sh +++ b/bin/searchtestmulti.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh cd "`dirname $0`" ./searchtest.sh ../test/words/searchtest.words.aa & sleep 1 diff --git a/bin/up.sh b/bin/up.sh index 414ac16de..895a0ea35 100755 --- a/bin/up.sh +++ b/bin/up.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash cd "`dirname $0`" ./apicall.sh "/Network.xml?page=1&ip=" | awk '/
/{ gsub("
","" );gsub("<\/address>","" ); print $0 }' | awk '{print $1}'; diff --git a/killYACY.sh b/killYACY.sh index a5db0ab42..26c10c95e 100755 --- a/killYACY.sh +++ b/killYACY.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh # THIS IS ONLY FOR EMERGENCY CASES # To stop YaCy, use stopYACY.sh diff --git a/reconfigureYACY.sh b/reconfigureYACY.sh index 33654e333..e86868efe 100755 --- a/reconfigureYACY.sh +++ b/reconfigureYACY.sh @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # THIS SCRIPT CAN BE USED TO EDIT SOME BASIC SETTINGS OF YACY # diff --git a/startYACY.sh b/startYACY.sh index eb4ed4dc5..ede26fd7e 100755 --- a/startYACY.sh +++ b/startYACY.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh JAVA="`which java`" CONFIGFILE="DATA/SETTINGS/yacy.conf" LOGFILE="yacy.log" diff --git a/stopYACY.sh b/stopYACY.sh index 7473a1ee5..1a679e68d 100755 --- a/stopYACY.sh +++ b/stopYACY.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh cd `dirname $0` bin/apicall.sh "Steering.html?shutdown=true" > /dev/null diff --git a/updateYACY.sh b/updateYACY.sh index f81935b0d..0e2d8c125 100755 --- a/updateYACY.sh +++ b/updateYACY.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/usr/bin/env sh cd `dirname $0` if [ -x `which wget` ]