From 48b9f6649024f681a6114c8c49dbc77ab36d5f9e Mon Sep 17 00:00:00 2001 From: Ben Busby Date: Sat, 11 Apr 2020 15:57:06 -0600 Subject: [PATCH] Fixed incorrect opensearch template, updated readme --- README.md | 7 +++++-- app/static/opensearch.template | 6 +++--- opensearch.py | 2 +- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index e23a1e7..dbffb9b 100644 --- a/README.md +++ b/README.md @@ -30,8 +30,11 @@ heroku open TODO ## Extra Steps -- Set Shoogle as your primary search engine - - From the main shoogle folder, run `python opensearch.py "\"` +#### Set Shoogle as your primary search engine +1. From the main shoogle folder, run `python opensearch.py "\"` +2. Rebuild and release your updated app + - `heroku container:push web` and then `heroku container:release web` +3. Update browser settings - Firefox (Desktop) - Navigate to your app's url, and click the 3 dot menu in the address bar. At the bottom, there should be an option to "Add Search Engine". Once you've clicked this, open your Firefox Preferences menu, click "Search" in the left menu, and use the available dropdown to select "Shoogle" from the list. - Firefox (Mobile) diff --git a/app/static/opensearch.template b/app/static/opensearch.template index 04f43b8..bcac38a 100644 --- a/app/static/opensearch.template +++ b/app/static/opensearch.template @@ -4,10 +4,10 @@ Shoogle: A lightweight, deployable Google search proxy for desktop/mobile that removes Javascript, AMP links, and ads UTF-8 /static/img/favicon.ico - + - - SHOOGLE_URL + + SHOOGLE_URL/search diff --git a/opensearch.py b/opensearch.py index 29482f9..420c776 100644 --- a/opensearch.py +++ b/opensearch.py @@ -9,7 +9,7 @@ if len(sys.argv) != 2: print('Example: python opensearch.py "https://my-app-1776.herokuapps.com"') sys.exit(0) -app_url = sys.argv[1] +app_url = sys.argv[1].rstrip('/') opensearch_template = open(template_path, 'r').read() with open(opensearch_path, 'w') as opensearch_xml: