Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
searx-engine
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
searx-engine
Commits
f4287b7e
Commit
f4287b7e
authored
May 18, 2017
by
Adam Tauber
Committed by
GitHub
May 18, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #925 from kvch/free-software-directory
Add free software directory engine
parents
9ee8e552
2a9339f4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
2 deletions
+16
-2
mediawiki.py
searx/engines/mediawiki.py
+4
-2
settings.yml
searx/settings.yml
+12
-0
No files found.
searx/engines/mediawiki.py
View file @
f4287b7e
...
...
@@ -21,6 +21,7 @@ categories = ['general']
language_support
=
True
paging
=
True
number_of_results
=
1
search_type
=
'nearmatch'
# possible values: title, text, nearmatch
# search-url
base_url
=
'https://{language}.wikipedia.org/'
...
...
@@ -30,7 +31,7 @@ search_postfix = 'w/api.php?action=query'\
'&format=json'
\
'&sroffset={offset}'
\
'&srlimit={limit}'
\
'&srwhat=
nearmatch'
# search for a near match in the title
'&srwhat=
{searchtype}'
# do search-request
...
...
@@ -39,7 +40,8 @@ def request(query, params):
string_args
=
dict
(
query
=
urlencode
({
'srsearch'
:
query
}),
offset
=
offset
,
limit
=
number_of_results
)
limit
=
number_of_results
,
searchtype
=
search_type
)
format_strings
=
list
(
Formatter
()
.
parse
(
base_url
))
...
...
searx/settings.yml
View file @
f4287b7e
...
...
@@ -209,6 +209,18 @@ engines:
# Or you can use the html non-stable engine, activated by default
engine
:
flickr_noapi
-
name
:
free software directory
engine
:
mediawiki
shortcut
:
fsd
categories
:
it
base_url
:
https://directory.fsf.org/
number_of_results
:
5
# what part of a page matches the query string: title, text, nearmatch
# title - query matches title, text - query matches the text of page, nearmatch - nearmatch in title
search_type
:
title
timeout
:
5.0
disabled
:
True
-
name
:
frinkiac
engine
:
frinkiac
shortcut
:
frk
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment