aboutsummaryrefslogtreecommitdiff
path: root/subprojects/freeamo
diff options
context:
space:
mode:
Diffstat (limited to 'subprojects/freeamo')
-rwxr-xr-xsubprojects/freeamo/freeamo8
-rw-r--r--subprojects/freeamo/src/main_functions2
-rw-r--r--subprojects/freeamo/src/make-wiki4
3 files changed, 11 insertions, 3 deletions
diff --git a/subprojects/freeamo/freeamo b/subprojects/freeamo/freeamo
index 9ee84f3..ac4d7c7 100755
--- a/subprojects/freeamo/freeamo
+++ b/subprojects/freeamo/freeamo
@@ -15,6 +15,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
scriptsrc=$(readlink -f -- "${BASH_SOURCE[0]}")
run_path=$(dirname "${scriptsrc}" || echo .)
filename=$(basename "$0");
@@ -25,6 +26,13 @@ source "$run_path/freeamo.conf"
source "$run_path/src/err"
+# if you don't have this locale, add this to /etc/locale.gen:
+# sv_SE.UTF-8 UTF-8
+# then run sudo locale-gen
+# then open a new terminal.
+export LC_NUMERIC=sv_SE.UTF-8
+
+
output_file_1="$run_path/build/index-search-pages.txt";
output_file_2="$run_path/build/index-search-pages--free-licenses.txt"
diff --git a/subprojects/freeamo/src/main_functions b/subprojects/freeamo/src/main_functions
index ad7c435..06ddad6 100644
--- a/subprojects/freeamo/src/main_functions
+++ b/subprojects/freeamo/src/main_functions
@@ -69,7 +69,7 @@ echo "####################"
tmp__enGB=$(jq ".results[$entry].$locale_description" "$file" | sed "s|-||;" | jq -r .enGB )
# Use the first avalible if English is not avaliable
- tmp=$(jq -r ".results[$entry].$locale_description[]" "$file" | head -n 1)
+ tmp=$(jq -r ".results[$entry].$locale_description[]" "$file" | head -n 1) || [[ $? == 141 ]] # jq causes superfluous 141
# David will work on this later
# if [ "$tmp" == "" ]; then
diff --git a/subprojects/freeamo/src/make-wiki b/subprojects/freeamo/src/make-wiki
index b4de1a6..94761b4 100644
--- a/subprojects/freeamo/src/make-wiki
+++ b/subprojects/freeamo/src/make-wiki
@@ -115,7 +115,7 @@ while IFS= read -r table; do
- github_true=$(echo "$homepage_url" | grep "github.com");
+ github_true=$(echo "$homepage_url" | grep "github.com") ||: # ok if grep fails
if [[ $github_true != "" ]]; then
@@ -213,7 +213,7 @@ at https://addons.mozilla.org/en-US/firefox/addon/adblock-plus/
fi
- echo "foo" # Must be here to work with pv
+ if ! $debug; then echo "foo"; fi # for pv
done < "$output_file_2" # | pv__progress
# End template