Merge remote-tracking branch 'refs/remotes/upstream/master'

This commit is contained in:
Sky Splash 2024-07-31 14:05:30 +02:00
commit 6cdf0284d4
39 changed files with 2166 additions and 387 deletions

View file

@ -35,7 +35,6 @@ RUN apk add --no-cache -t build-dependencies \
git \
&& apk add --no-cache \
ca-certificates \
su-exec \
python3 \
py3-pip \
libxml2 \

View file

@ -175,4 +175,4 @@ unset MORTY_KEY
# Start uwsgi
printf 'Listen on %s\n' "${BIND_ADDRESS}"
exec su-exec searxng:searxng uwsgi --master --http-socket "${BIND_ADDRESS}" "${UWSGI_SETTINGS_PATH}"
exec uwsgi --master --uid searxng --gid searxng --http-socket "${BIND_ADDRESS}" "${UWSGI_SETTINGS_PATH}"

View file

@ -339,6 +339,8 @@ type.
content *(not implemented yet)*
publishedDate :py:class:`datetime.datetime`, time of publish
thumbnail string, url to a small-preview image
length :py:class:`datetime.timedelta`, duration of result
views string, view count in humanized number format
========================= =====================================================

View file

@ -0,0 +1,8 @@
.. _gitea geizhals:
========
Geizhals
========
.. automodule:: searx.engines.geizhals
:members:

View file

@ -2,12 +2,12 @@ mock==5.1.0
nose2[coverage_plugin]==0.15.1
cov-core==1.15.0
black==24.3.0
pylint==3.2.5
pylint==3.2.6
splinter==0.21.0
selenium==4.22.0
selenium==4.23.1
Pallets-Sphinx-Themes==2.1.3
Sphinx<=7.1.2; python_version == '3.8'
Sphinx==7.3.7; python_version > '3.8'
Sphinx==7.4.7; python_version > '3.8'
sphinx-issues==4.1.0
sphinx-jinja==2.0.2
sphinx-tabs==3.4.5

File diff suppressed because it is too large Load diff

View file

@ -721,7 +721,7 @@
"ar": "ريال برازيلي",
"bg": "Бразилски реал",
"bn": "ব্রাজিলীয় রিয়েল",
"ca": "real",
"ca": "real brasiler",
"cs": "Brazilský real",
"da": "brasiliansk real",
"de": "brasilianischer Real",
@ -1105,7 +1105,7 @@
"de": "chilenischer Peso",
"en": "Chilean peso",
"eo": "ĉilia peso",
"es": "peso chileno",
"es": "peso",
"et": "Tšiili peeso",
"eu": "Peso txiletar",
"fi": "Chilen peso",
@ -1368,7 +1368,7 @@
"sr": "чешка круна",
"sv": "tjeckisk krona",
"ta": "செக் கொருனா",
"th": "โรูนาเช็ก",
"th": "โรูนาเช็ก",
"tr": "Çek korunası",
"uk": "чеська крона",
"vi": "Koruna Séc"
@ -1793,7 +1793,7 @@
"ar": "لاري جورجي",
"bg": "Грузинско лари",
"ca": "lari",
"cs": "Gruzínské lari",
"cs": "gruzínské lari",
"da": "Lari",
"de": "georgischer Lari",
"en": "Georgian lari",
@ -1948,6 +1948,7 @@
"es": "Franco guineano",
"fi": "Guinean frangi",
"fr": "franc guinéen",
"gl": "franco guineano",
"he": "פרנק גינאי",
"hr": "Gvinejski franak",
"hu": "guineai frank",
@ -2064,7 +2065,7 @@
"ko": "홍콩 달러",
"lt": "Honkongo doleris",
"ml": "ഹോങ്കോങ്ങ് ഡോളർ",
"ms": "Dolar Hong Kong",
"ms": "dolar Hong Kong",
"nl": "Hongkongse dollar",
"oc": "dolar de Hong Kong",
"pa": "ਹਾਂਗਕਾਂਗ ਡਾਲਰ",
@ -2073,6 +2074,7 @@
"ro": "dolar din Hong Kong",
"ru": "гонконгский доллар",
"sk": "Hongkonský dolár",
"sl": "hongkonški dolar",
"sr": "хонгконшки долар",
"sv": "Hongkongdollar",
"ta": "ஹொங்கொங் டொலர்",
@ -2203,6 +2205,7 @@
"eu": "Indonesiar errupia",
"fi": "Indonesian rupia",
"fr": "roupie indonésienne",
"gl": "rupia indonesia",
"he": "רופיה אינדונזית",
"hr": "Indonezijska rupija",
"hu": "indonéz rúpia",
@ -2213,7 +2216,7 @@
"lt": "Indonezijos rupija",
"lv": "Indonēzijas rūpija",
"ml": "റുപിയ",
"ms": "Rupiah Indonesia",
"ms": "rupiah Indonesia",
"nl": "Indonesische roepia",
"oc": "ropia d'Indonesia",
"pa": "ਇੰਡੋਨੇਸ਼ੀਆਈ ਰੂਪੀਆ",
@ -2498,6 +2501,7 @@
"pt": "dinar jordano",
"ro": "Dinar iordanian",
"ru": "иорданский динар",
"sk": "Jordánsky dinár",
"sl": "jordanski dinar",
"sr": "јордански динар",
"sv": "Jordansk dinar",
@ -2827,6 +2831,7 @@
"pl": "Dolar kajmański",
"pt": "Dólar das Ilhas Cayman",
"ru": "доллар Каймановых островов",
"sl": "kajmanji dolar",
"sr": "долар Кајманских Острва",
"sv": "Caymansk dollar",
"tr": "Cayman Adaları doları",
@ -3324,6 +3329,7 @@
"pl": "Pataca",
"pt": "Pataca",
"ru": "патака Макао",
"sl": "makavska pataka",
"sr": "макаонска патака",
"sv": "Macaoisk Pataca",
"tr": "Pataka",
@ -3423,6 +3429,7 @@
"pl": "Rupia malediwska",
"pt": "Rupia maldívia",
"ru": "мальдивская руфия",
"sl": "maldivska rufija",
"sr": "малдивска руфија",
"sv": "Rufiyah",
"ta": "மாலத்தீவின் ருஃபியா",
@ -3748,6 +3755,7 @@
"lt": "Nepalo rupija",
"ml": "നേപ്പാളി രൂപ",
"nl": "Nepalese roepie",
"oc": "Ropia nepalesa",
"pa": "ਨੇਪਾਲੀ ਰੁਪਈਆ",
"pl": "Rupia nepalska",
"pt": "Rupia nepalesa",
@ -4143,7 +4151,7 @@
"eo": "katara rialo",
"es": "riyal catarí",
"fi": "Qatarin rial",
"fr": "Riyal qatarien",
"fr": "riyal qatarien",
"he": "ריאל קטרי",
"hr": "Katarski rijal",
"hu": "katari riál",
@ -4234,6 +4242,7 @@
"lt": "Serbijos dinaras",
"lv": "Serbijas dinārs",
"nl": "Servische dinar",
"oc": "dinar sèrbe",
"pa": "ਸਰਬੀਆਈ ਦਿਨਾਰ",
"pl": "Dinar serbski",
"pt": "dinar sérvio",
@ -4245,7 +4254,8 @@
"sv": "Serbisk dinar",
"ta": "செர்பிய தினார்",
"tr": "Sırp dinarı",
"uk": "сербський динар"
"uk": "сербський динар",
"vi": "Dinar Serbia"
},
"RUB": {
"af": "Russiese roebel",
@ -4539,6 +4549,7 @@
"pt": "dólar de Singapura",
"ru": "сингапурский доллар",
"si": "සිංගප්පූරු ඩොලරය",
"sl": "singapurski dolar",
"sr": "сингапурски долар",
"sv": "Singaporiansk dollar",
"ta": "சிங்கப்பூர் வெள்ளி",
@ -4840,7 +4851,7 @@
"ar": "بات تايلاندي",
"bg": "Тайландски бат",
"bn": "থাই বাত",
"ca": "Baht",
"ca": "baht",
"cs": "Thajský baht",
"cy": "Baht",
"da": "thailandsk baht",
@ -5532,17 +5543,17 @@
"cs": "investiční zlato",
"de": "Gold als Kapitalanlage",
"en": "gold as an investment",
"fi": "Kultaan sijoittaminen",
"fi": "kultaan sijoittaminen",
"fr": "or d'investissement",
"hu": "befektetési arany",
"ja": "金投資",
"ko": "금 투자",
"lv": "Zelts kā investīcija",
"lv": "zelts kā investīcija",
"ml": "സ്വർണവും സാമ്പത്തിക ശാസ്ത്രവും",
"ms": "Emas sebagai pelaburan",
"ms": "emas sebagai pelaburan",
"ru": "золото как инвестиция",
"sr": "Investiciono zlato",
"sv": "Investeringsguld",
"sr": "investiciono zlato",
"sv": "investeringsguld",
"vi": "Kênh đầu tư vàng"
},
"XBA": {
@ -5608,7 +5619,7 @@
"fi": "Erityisnosto-oikeus",
"fr": "droits de tirage spéciaux",
"hr": "Posebna prava vučenja",
"hu": "SDR",
"hu": "különleges lehívási jog",
"id": "Hak penarikan khusus",
"it": "diritti speciali di prelievo",
"ja": "特別引出権",
@ -5842,6 +5853,26 @@
"tr": "Zambiya kwachası",
"uk": "Замбійська квача"
},
"ZWG": {
"af": "Zimbabwe Goud",
"ar": "ذهب زيمبابوي",
"ca": "or de Zimbàbue",
"cs": "zimbabwský zlatý",
"de": "Simbabwe-Gold",
"en": "Zimbabwe Gold",
"eo": "Zimbabva Oro",
"es": "Oro de Zimbabue",
"fr": "or du Zimbabwe",
"id": "Zimbabwe Gold",
"ja": "ジンバブエ・ゴールド",
"ko": "짐바브웨 골드",
"nl": "Zimbabwe Gold",
"pl": "Złoto Zimbabwe",
"ru": "зимбабвийский золотой",
"sk": "zimbabwiansky zlatý",
"sl": "zimbabvejski gold",
"tr": "Zimbabve altını"
},
"ZWL": {
"ca": "dòlar de Zimbàbue",
"cs": "zimbabwský dolar",
@ -6157,6 +6188,7 @@
"ariari": "MGA",
"ariari de madagascar": "MGA",
"ariari de madagáscar": "MGA",
"ariari malgache": "MGA",
"ariari malgaxe": "MGA",
"ariaris": "MGA",
"ariaro": "MGA",
@ -6295,6 +6327,7 @@
"bahreyn dinarı": "BHD",
"baht": "THB",
"baht tailandes": "THB",
"baht tailandès": "THB",
"baht tailandés": "THB",
"baht tailandês": "THB",
"baht thailand": "THB",
@ -6341,6 +6374,7 @@
"barbadoso doleris": "BBD",
"barejna dinaro": "BHD",
"bat": "THB",
"bat tailandés": "THB",
"batas": "THB",
"bath": "THB",
"bati": "THB",
@ -6418,6 +6452,7 @@
"bif": "BIF",
"bigarren boliviano": "BOB",
"bir": "ETB",
"bir etíope": "ETB",
"biras": "ETB",
"birleşik arap emirlikleri dirhemi": "AED",
"birma kjato": "MMK",
@ -7046,6 +7081,7 @@
"dinar serbia": "RSD",
"dinar serbio": "RSD",
"dinar serbski": "RSD",
"dinar sèrbe": "RSD",
"dinar sérvio": "RSD",
"dinar soudanais": "SDG",
"dinar tiwnisaidd": "TND",
@ -7167,6 +7203,8 @@
"doğu karayip doları": "XCD",
"dolar": [
"NZD",
"KYD",
"HKD",
"FJD",
"BSD"
],
@ -7516,6 +7554,7 @@
"dòlar fijià": "FJD",
"dòlar jamaicà": "JMD",
"dòlar liberià": "LRD",
"dòlar malai": "MYR",
"dòlar namibi": "NAD",
"dòlar namibià": "NAD",
"dòlar neozelandès": "NZD",
@ -8252,6 +8291,7 @@
],
"gulden antyli holenderskich": "ANG",
"gulden nizozemských antil": "ANG",
"gultrum butanés": "BTN",
"gurdas": "HTG",
"gurde": "HTG",
"gurde haitiano": "HTG",
@ -8368,6 +8408,7 @@
"id": "IQD",
"idr": "IDR",
"ien": "JPY",
"ien japonès": "JPY",
"iene": "JPY",
"igorpen eskubide bereziak": "XDR",
"iisraeli seekel": "ILS",
@ -8565,6 +8606,7 @@
"jordansk dinar": "JOD",
"jordanski dinar": "JOD",
"jordán dinár": "JOD",
"jordánsky dinár": "JOD",
"jordánský dinár": "JOD",
"jpy": "JPY",
"juan": "CNY",
@ -8593,6 +8635,7 @@
"kaimanų doleris": "KYD",
"kaimanų salų doleris": "KYD",
"kajmana dolaro": "KYD",
"kajmanji dolar": "KYD",
"kajmanski dolar": "KYD",
"kajmán szigeteki dollár": "KYD",
"kambodjansk riel": "KHR",
@ -8815,6 +8858,7 @@
"krw": "KRW",
"ks": "MMK",
"ksh": "KES",
"kuanza angoleño": "AOA",
"kuba peso": "CUP",
"kubai peso": "CUP",
"kubanischer peso": "CUP",
@ -8844,6 +8888,8 @@
"kuzey kore wonu": "KPW",
"küba pesosu": "CUP",
"küba pezosu": "CUP",
"különleges kibocsátási jogok": "XDR",
"különleges lehívási jog": "XDR",
"kvača": "MWK",
"kvanza": "AOA",
"kvecal": "GTQ",
@ -9279,6 +9325,7 @@
"makao patakası": "MOP",
"makaonska pataka": "MOP",
"makaói pataca": "MOP",
"makavska pataka": "MOP",
"makedon denarı": "MKD",
"makedon dinarı": "MKD",
"makedona denaro": "MKD",
@ -9711,6 +9758,7 @@
"nordkoreanischer won": "KPW",
"nordkoreansk won": "KPW",
"nordkoreanske won": "KPW",
"nordmazedonischer denar": "MKD",
"norjan kruunu": "NOK",
"norra kroon": "NOK",
"norsk krona": "NOK",
@ -9878,9 +9926,12 @@
"oost caraïbische dollar": "XCD",
"oost caribische dollar": "XCD",
"or d'investissement": "XAU",
"or de zimbàbue": "ZWG",
"or du zimbabwe": "ZWG",
"orient kariba dolaro": "XCD",
"orientkariba dolaro": "XCD",
"orientkaribia dolaro": "XCD",
"oro de zimbabue": "ZWG",
"orosz rubel": "RUB",
"orta afrika cfa frangı": "XAF",
"orta afrika cfa frankı": "XAF",
@ -10406,6 +10457,7 @@
"rijalo": "SAR",
"ringgit": "MYR",
"ringgit brunei": "BND",
"ringgit malai": "MYR",
"ringgit malaio": "MYR",
"ringgit malaysia": "MYR",
"ringgit malaysiano": "MYR",
@ -10421,9 +10473,11 @@
"riyal da arábia saudita": "SAR",
"riyal de qatar": "QAR",
"riyal dell'oman": "OMR",
"riyal du qatar": "QAR",
"riyal iraniano": "IRR",
"riyal oman": "OMR",
"riyal qatar": "QAR",
"riyal qatari": "QAR",
"riyal qatarien": "QAR",
"riyal qatariota": "QAR",
"riyal saoudien": "SAR",
@ -10450,6 +10504,7 @@
"ropia d'índia": "INR",
"ropia de maurici": "MUR",
"ropia de paquistan": "PKR",
"ropia nepalesa": "NPR",
"rouble biélorusse": "BYN",
"rouble russe": "RUB",
"roupie du népal": "NPR",
@ -10898,6 +10953,7 @@
"silver as an investment": "XAG",
"silver as currency": "XAG",
"silver som investering": "XAG",
"simbabwe gold": "ZWG",
"singapoer dollar": "SGD",
"singapore dollar": "SGD",
"singaporeansk dollar": "SGD",
@ -11254,6 +11310,7 @@
"taka bangladesi": "BDT",
"taka bangladesí": "BDT",
"taka bengalese": "BDT",
"taka bengalí": "BDT",
"taka bengalska": "BDT",
"tala": "WST",
"tala samoan": "WST",
@ -11777,11 +11834,20 @@
"zeelandako dolarra": "NZD",
"zelenortski eskudo": "CVE",
"zelts kā investīcija": "XAU",
"zig": "ZWG",
"zimbabva dolaro": "ZWL",
"zimbabva oro": "ZWG",
"zimbabve altını": "ZWG",
"zimbabvejski dolar": "ZWL",
"zimbabvejski gold": "ZWG",
"zimbabwaanse dollar": "ZWL",
"zimbabwe gold": "ZWG",
"zimbabwe goud": "ZWG",
"zimbabwean dollar": "ZWL",
"zimbabwean zig": "ZWG",
"zimbabwiansky zlatý": "ZWG",
"zimbabwský dolar": "ZWL",
"zimbabwský zlatý": "ZWG",
"zimdollar": "ZWL",
"zl": [
"PLZ",
@ -11886,6 +11952,7 @@
"PLZ",
"PLN"
],
"złoto zimbabwe": "ZWG",
"złoty": [
"PLZ",
"PLN"
@ -12323,6 +12390,7 @@
"гибралтарска лира": "GIP",
"гибралтарска фунта": "GIP",
"гибралтарский фунт": "GIP",
"голд": "ZWG",
"гондурасская лемпира": "HNL",
"гондураська лемпіра": "HNL",
"гонконгзький долар": "HKD",
@ -12457,6 +12525,9 @@
"западноафриканский франк кфа": "XOF",
"західноафриканський франк": "XOF",
"зеленортски ескудо": "CVE",
"зиг": "ZWG",
"зимбабвийский голд": "ZWG",
"зимбабвийский золотой": "ZWG",
"злот": [
"PLZ",
"PLN"
@ -12471,6 +12542,7 @@
],
"золотая кордоба": "NIO",
"золото как инвестиция": "XAU",
"золотой": "ZWG",
"йеменски риал": "YER",
"йеменский риал": "YER",
"йена": "JPY",
@ -13610,6 +13682,7 @@
"دينار كويتي": "KWD",
"دينار ليبي": "LYD",
"دينار مقدوني": "MKD",
"ذهب زيمبابوي": "ZWG",
"ر.س": "SAR",
"ر.ع.": "OMR",
"ر.ق": "QAR",
@ -13673,6 +13746,7 @@
"سول بيروي جديد": "PEN",
"سوم أوزبكستاني": "UZS",
"سوم أوزبيكستاني": "UZS",
"سوم قرغيزي": "KGS",
"سوم قيرغيزستاني": "KGS",
"سيدي غاني": "GHS",
"شاقل جديد": "ILS",
@ -14110,6 +14184,7 @@
"యునైటెడ్ స్టేట్స్ డాలర్": "USD",
"యూరో": "EUR",
"రూపాయి": "INR",
"సంయుక్త రాష్ట్రాల డాలర్": "USD",
"స్విస్ ఫ్రాంక్": "CHF",
"അൾജീരിയൻ ദിനാർ": "DZD",
"ഇന്തോനേഷ്യൻ റുപിയ": "IDR",
@ -14240,7 +14315,7 @@
"เหยินหมินปี้": "CNY",
"เหรินหมินปี้": "CNY",
"แดนาร์มาซิโดเนีย": "MKD",
"โรูนาเช็ก": "CZK",
"โรูนาเช็ก": "CZK",
"โครเนอเดนมาร์ก": "DKK",
"โฟรินต์ฮังการี": "HUF",
"ไนรา": "NGN",
@ -14485,6 +14560,7 @@
"지부티 프랑": "DJF",
"지부티프랑": "DJF",
"지브롤터 파운드": "GIP",
"짐바브웨 골드": "ZWG",
"짯": "MMK",
"챠트": "MMK",
"체코 코루나": "CZK",
@ -14710,6 +14786,7 @@
"ジブラルタル・ポンド": "GIP",
"ジャマイカドル": "JMD",
"ジャマイカ・ドル": "JMD",
"ジンバブエ・ゴールド": "ZWG",
"シエラレオネの通貨": [
"SLL",
"SLE"

File diff suppressed because it is too large Load diff

View file

@ -6,20 +6,21 @@
"book_nonfiction",
"book_fiction",
"book_unknown",
"book_comic",
"magazine",
"standards_document"
"book_comic",
"standards_document",
"musical_score"
],
"ext": [
"pdf",
"epub",
"fb2",
"cbr",
"mobi",
"cbz",
"azw3",
"cbr",
"djvu",
"txt"
"txt",
"cbz",
"azw3"
],
"sort": [
"",
@ -46,6 +47,7 @@
"cy": "cy",
"da": "da",
"de": "de",
"dz": "dz",
"el": "el",
"en": "en",
"eo": "eo",
@ -77,7 +79,6 @@
"ml": "ml",
"mn": "mn",
"mr": "mr",
"ms": "ms",
"nl": "nl",
"no": "no",
"pl": "pl",
@ -85,7 +86,6 @@
"ro": "ro",
"ru": "ru",
"rw": "rw",
"sa": "sa",
"sk": "sk",
"sl": "sl",
"sr": "sr",
@ -1761,6 +1761,7 @@
"fr-FR": "fr-fr",
"hr": "hr",
"hu": "hu",
"id": "id",
"it": "it",
"ja-JP": "ja-jp",
"lt": "lt",
@ -1777,7 +1778,8 @@
"sv": "sv",
"sw-KE": "sw-ke",
"tr": "tr",
"uk": "uk"
"uk": "uk",
"zh_Hant": "zh-hant"
}
},
"data_type": "traits_v1",
@ -1853,6 +1855,7 @@
"fr-FR": "fr-fr",
"hr": "hr",
"hu": "hu",
"id": "id",
"it": "it",
"ja-JP": "ja-jp",
"lt": "lt",
@ -1869,7 +1872,8 @@
"sv": "sv",
"sw-KE": "sw-ke",
"tr": "tr",
"uk": "uk"
"uk": "uk",
"zh_Hant": "zh-hant"
}
},
"data_type": "traits_v1",
@ -1945,6 +1949,7 @@
"fr-FR": "fr-fr",
"hr": "hr",
"hu": "hu",
"id": "id",
"it": "it",
"ja-JP": "ja-jp",
"lt": "lt",
@ -1961,7 +1966,8 @@
"sv": "sv",
"sw-KE": "sw-ke",
"tr": "tr",
"uk": "uk"
"uk": "uk",
"zh_Hant": "zh-hant"
}
},
"data_type": "traits_v1",
@ -2037,6 +2043,7 @@
"fr-FR": "fr-fr",
"hr": "hr",
"hu": "hu",
"id": "id",
"it": "it",
"ja-JP": "ja-jp",
"lt": "lt",
@ -2053,7 +2060,8 @@
"sv": "sv",
"sw-KE": "sw-ke",
"tr": "tr",
"uk": "uk"
"uk": "uk",
"zh_Hant": "zh-hant"
}
},
"data_type": "traits_v1",
@ -6243,7 +6251,6 @@
"MQ",
"MT",
"MU",
"MV",
"MW",
"MX",
"MY",
@ -6270,6 +6277,7 @@
"PR",
"PS",
"PT",
"PW",
"PY",
"QA",
"RE",
@ -6337,7 +6345,6 @@
"am": "amharic",
"ar": "arabic",
"as": "assamese",
"ast": "asturian",
"az": "azerbaijani",
"ba": "bashkir",
"be": "belarusian",
@ -6380,7 +6387,6 @@
"hu": "hungarian",
"hy": "armenian",
"id": "indonesian",
"ig": "igbo",
"is": "icelandic",
"it": "italian",
"iu": "inuktitut",
@ -6393,9 +6399,11 @@
"kn": "kannada",
"ko": "korean",
"ku": "kurdish",
"kw": "cornish",
"la": "latin",
"lb": "luxembourgish",
"ln": "lingala",
"lo": "lao",
"lt": "lithuanian",
"lv": "latvian",
"mg": "malagasy",
@ -6698,7 +6706,6 @@
"ml": "ml",
"mn": "mn",
"mr": "mr",
"ms": "ms",
"nb": "no",
"ne": "ne",
"or": "or",
@ -7131,7 +7138,6 @@
"ml": "ml.wikipedia.org",
"mn": "mn.wikipedia.org",
"mr": "mr.wikipedia.org",
"ms": "ms.wikipedia.org",
"ne": "ne.wikipedia.org",
"no": "no.wikipedia.org",
"or": "or.wikipedia.org",
@ -7220,7 +7226,6 @@
"ml": "ml",
"mn": "mn",
"mr": "mr",
"ms": "ms",
"nb": "no",
"ne": "ne",
"or": "or",

View file

@ -5,7 +5,7 @@
],
"ua": "Mozilla/5.0 ({os}; rv:{version}) Gecko/20100101 Firefox/{version}",
"versions": [
"127.0",
"126.0"
"128.0",
"127.0"
]
}

File diff suppressed because it is too large Load diff

View file

@ -430,10 +430,10 @@ def fetch_traits(engine_traits: EngineTraits):
ui_lang = option.get('value')
try:
if '-' in ui_lang:
if '-' in ui_lang and not ui_lang.startswith("zh-"):
sxng_tag = region_tag(babel.Locale.parse(ui_lang, sep='-'))
else:
sxng_tag = language_tag(babel.Locale.parse(ui_lang))
sxng_tag = language_tag(babel.Locale.parse(ui_lang, sep='-'))
except babel.UnknownLocaleError:
print("ERROR: can't determine babel locale of Brave's (UI) language %s" % ui_lang)

View file

@ -10,6 +10,8 @@ engine offers some additional settings:
- :py:obj:`api_order`
- :py:obj:`search_endpoint`
- :py:obj:`show_avatar`
- :py:obj:`api_key`
- :py:obj:`api_username`
Example
=======
@ -27,6 +29,20 @@ for the ``paddling.com`` forum:
categories: ['social media', 'sports']
show_avatar: true
If the forum is private, you need to add an API key and username for the search:
.. code:: yaml
- name: paddling
engine: discourse
shortcut: paddle
base_url: 'https://forums.paddling.com/'
api_order: views
categories: ['social media', 'sports']
show_avatar: true
api_key: '<KEY>'
api_username: 'system'
Implementations
===============
@ -65,6 +81,12 @@ api_order = 'likes'
show_avatar = False
"""Show avatar of the user who send the post."""
api_key = ''
"""API key of the Discourse forum."""
api_username = ''
"""API username of the Discourse forum."""
paging = True
time_range_support = True
@ -98,6 +120,12 @@ def request(query, params):
'X-Requested-With': 'XMLHttpRequest',
}
if api_key != '':
params['headers']['Api-Key'] = api_key
if api_username != '':
params['headers']['Api-Username'] = api_username
return params

97
searx/engines/geizhals.py Normal file
View file

@ -0,0 +1,97 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""Geizhals is a German website to compare the price of a product on the
most common German shopping sites and find the lowest price.
The sorting of the search results can be influenced by the following additions
to the search term:
``asc`` or ``price``
To sort by price in ascending order.
``desc``
To sort by price in descending order.
"""
import re
from urllib.parse import urlencode
from lxml import html
from searx.utils import eval_xpath, eval_xpath_list, extract_text
about = {
'website': 'https://geizhals.de',
'wikidata_id': 'Q15977657',
'use_official_api': False,
'official_api_documentation': None,
'require_api_key': False,
'results': 'HTML',
'language': 'de',
}
paging = True
categories = ['shopping']
base_url = "https://geizhals.de"
sort_order = 'relevance'
SORT_RE = re.compile(r"sort:(\w+)")
sort_order_map = {
'relevance': None,
'price': 'p',
'asc': 'p',
'desc': '-p',
}
def request(query, params):
sort = None
sort_order_path = SORT_RE.search(query)
if sort_order_path:
sort = sort_order_map.get(sort_order_path.group(1))
query = SORT_RE.sub("", query)
logger.debug(query)
args = {
'fs': query,
'pg': params['pageno'],
'toggle_all': 1, # load item specs
'sort': sort,
}
params['url'] = f"{base_url}/?{urlencode(args)}"
return params
def response(resp):
results = []
dom = html.fromstring(resp.text)
for result in eval_xpath_list(dom, "//article[contains(@class, 'listview__item')]"):
content = []
for spec in eval_xpath_list(result, ".//div[contains(@class, 'specs-grid__item')]"):
content.append(f"{extract_text(eval_xpath(spec, './dt'))}: {extract_text(eval_xpath(spec, './dd'))}")
metadata = [
extract_text(eval_xpath(result, ".//div[contains(@class, 'stars-rating-label')]")),
extract_text(eval_xpath(result, ".//div[contains(@class, 'listview__offercount')]")),
]
item = {
'template': 'products.html',
'url': (
base_url + "/" + extract_text(eval_xpath(result, ".//a[contains(@class, 'listview__name-link')]/@href"))
),
'title': extract_text(eval_xpath(result, ".//h3[contains(@class, 'listview__name')]")),
'content': ' | '.join(content),
'thumbnail': extract_text(eval_xpath(result, ".//img[contains(@class, 'listview__image')]/@src")),
'metadata': ', '.join(item for item in metadata if item),
}
best_price = extract_text(eval_xpath(result, ".//a[contains(@class, 'listview__price-link')]")).split(" ")
if len(best_price) > 1:
item["price"] = f"Bestes Angebot: {best_price[1]}"
results.append(item)
return results

View file

@ -7,6 +7,8 @@ import random
from urllib.parse import quote_plus, urlparse
from dateutil import parser
from searx.utils import humanize_number
# about
about = {
"website": 'https://api.invidious.io/',
@ -91,7 +93,8 @@ def response(resp):
"url": url,
"title": result.get("title", ""),
"content": result.get("description", ""),
'length': length,
"length": length,
"views": humanize_number(result['viewCount']),
"template": "videos.html",
"author": result.get("author"),
"publishedDate": publishedDate,

View file

@ -14,7 +14,7 @@ import babel
from searx.network import get # see https://github.com/searxng/searxng/issues/762
from searx.locales import language_tag
from searx.utils import html_to_text
from searx.utils import html_to_text, humanize_number
from searx.enginelib.traits import EngineTraits
traits: EngineTraits
@ -124,6 +124,7 @@ def video_response(resp):
'content': html_to_text(result.get('description') or ''),
'author': result.get('account', {}).get('displayName'),
'length': minute_to_hm(result.get('duration')),
'views': humanize_number(result['views']),
'template': 'videos.html',
'publishedDate': parse(result['publishedAt']),
'iframe_src': result.get('embedUrl'),

View file

@ -53,6 +53,8 @@ from urllib.parse import urlencode
import datetime
from dateutil import parser
from searx.utils import humanize_number
# about
about = {
"website": 'https://github.com/TeamPiped/Piped/',
@ -138,6 +140,7 @@ def response(resp):
"title": result.get("title", ""),
"publishedDate": parser.parse(time.ctime(uploaded / 1000)) if uploaded != -1 else None,
"iframe_src": _frontend_url() + '/embed' + result.get("url", ""),
"views": humanize_number(result["views"]),
}
length = result.get("duration")
if length:

View file

@ -118,6 +118,8 @@ def _base_url() -> str:
url = engines['yacy'].base_url # type: ignore
if isinstance(url, list):
url = random.choice(url)
if url.endswith("/"):
url = url[:-1]
return url

View file

@ -623,6 +623,24 @@ engines:
shortcut: dh
categories: [it, packages]
- name: encyclosearch
engine: json_engine
shortcut: es
categories: general
paging: true
search_url: https://encyclosearch.org/encyclosphere/search?q={query}&page={pageno}&resultsPerPage=15
results_query: Results
url_query: SourceURL
title_query: Title
content_query: Description
disabled: true
about:
website: https://encyclosearch.org
official_api_documentation: https://encyclosearch.org/docs/#/rest-api
use_official_api: true
require_api_key: false
results: JSON
- name: erowid
engine: xpath
paging: true
@ -797,6 +815,11 @@ engines:
timeout: 8.0
disabled: true
- name: geizhals
engine: geizhals
shortcut: geiz
disabled: true
- name: genius
engine: genius
shortcut: gen
@ -2139,28 +2162,35 @@ engines:
disabled: true
- name: yacy
# https://docs.searxng.org/dev/engines/online/yacy.html
engine: yacy
categories: general
search_type: text
base_url:
- https://yacy.searchlab.eu
- https://search.lomig.me
- https://yacy.ecosys.eu
- https://search.webproject.link
# see https://github.com/searxng/searxng/pull/3631#issuecomment-2240903027
# - https://search.kyun.li
# - https://yacy.securecomcorp.eu
# - https://yacy.myserv.ca
# - https://yacy.nsupdate.info
# - https://yacy.electroncash.de
shortcut: ya
disabled: true
# required if you aren't using HTTPS for your local yacy instance
# https://docs.searxng.org/dev/engines/online/yacy.html
# enable_http: true
# timeout: 3.0
# search_mode: 'global'
# if you aren't using HTTPS for your local yacy instance disable https
# enable_http: false
search_mode: 'global'
# timeout can be reduced in 'local' search mode
timeout: 5.0
- name: yacy images
engine: yacy
network: yacy
categories: images
search_type: image
shortcut: yai
disabled: true
# timeout can be reduced in 'local' search mode
timeout: 5.0
- name: rumble
engine: rumble

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -271,6 +271,7 @@ article[data-vim-selected].category-social {
.published_date,
.result_length,
.result_views,
.result_author,
.result_shipping,
.result_source_country {

View file

@ -76,7 +76,6 @@ sxng_locales = (
('lv', 'Latviešu', '', 'Latvian', '\U0001f310'),
('ml', 'മലയാളം', '', 'Malayalam', '\U0001f310'),
('mr', 'मराठी', '', 'Marathi', '\U0001f310'),
('ms', 'Melayu', '', 'Malay', '\U0001f310'),
('nb', 'Norsk Bokmål', '', 'Norwegian Bokmål', '\U0001f310'),
('nb-NO', 'Norsk Bokmål', 'Norge', 'Norwegian Bokmål', '\U0001f1f3\U0001f1f4'),
('nl', 'Nederlands', '', 'Dutch', '\U0001f310'),

View file

@ -1,12 +1,11 @@
<select class="language" id="language" name="language" aria-label="{{ _('Search language') }}">{{- '' -}}
<option value="all" {% if current_language == 'all' %}selected="selected"{% endif %}>{{ _('Default language') }} [all]</option>{{- '' -}}
<option value="all"
{%- if current_language == 'all' %} selected="selected" {%- endif -%}>
{{- _('Default language') }} [all] {{- '' -}}
</option>{{- '' -}}
<option value="auto"
{%- if current_language == 'auto' %} selected="selected" {%- endif -%}>
{{- _('Auto-detect') }} [auto] {{- '' -}}
{{- _('Auto-detect') }} ({{ search_language }}) {{- '' -}}
</option>{{- '' -}}
{% for sxng_tag,lang_name,country_name,english_name,flag in sxng_locales | sort(attribute=1) -%}
<option value="{{ sxng_tag }}"

View file

@ -33,6 +33,7 @@
{%- macro result_sub_header(result) -%}
{%- if result.publishedDate %}<time class="published_date" datetime="{{ result.pubdate }}" >{{ result.publishedDate }}</time>{% endif -%}
{%- if result.length %}<div class="result_length">{{ _('Length') }}: {{ result.length }}</div>{% endif -%}
{%- if result.views %}<div class="result_views">{{ _('Views') }}: {{ result.views }}</div>{% endif -%}
{%- if result.author %}<div class="result_author">{{ _('Author') }}: {{ result.author }}</div>{% endif -%}
{%- if result.metadata %}<div class="highlight">{{ result.metadata|safe }}</div>{% endif -%}
{%- endmacro -%}

View file

@ -7,7 +7,7 @@
{% if result.source_country %}<div class="result_source_country">{{ result.source_country }}</div></br>{% endif %}
{%- if result.content %}
<p class="content">
{{ result.content }}
{{ result.content|safe }}
</p>
{% endif -%}
{{- result_sub_footer(result, proxify) -}}

View file

@ -27,7 +27,7 @@ msgstr ""
"Project-Id-Version: searx\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-06-17 12:15+0000\n"
"PO-Revision-Date: 2024-06-18 21:18+0000\n"
"PO-Revision-Date: 2024-07-13 12:18+0000\n"
"Last-Translator: return42 <return42@users.noreply.translate.codeberg.org>\n"
"Language-Team: German <https://translate.codeberg.org/projects/searxng/"
"searxng/de/>\n"
@ -36,7 +36,7 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.5.5\n"
"X-Generator: Weblate 5.6.2\n"
"Generated-By: Babel 2.15.0\n"
#. CONSTANT_NAMES['NO_SUBGROUPING']
@ -107,7 +107,7 @@ msgstr "Karte"
#. CATEGORY_NAMES['ONIONS']
#: searx/searxng.msg
msgid "onions"
msgstr "Zwiebel"
msgstr "onions"
#. CATEGORY_NAMES['SCIENCE']
#: searx/searxng.msg

View file

@ -20,15 +20,16 @@ msgstr ""
"Project-Id-Version: searx\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-06-17 12:15+0000\n"
"PO-Revision-Date: 2024-04-06 00:18+0000\n"
"Last-Translator: tegcope <tegcope@users.noreply.translate.codeberg.org>\n"
"PO-Revision-Date: 2024-07-13 12:18+0000\n"
"Last-Translator: return42 <return42@users.noreply.translate.codeberg.org>\n"
"Language-Team: Persian <https://translate.codeberg.org/projects/searxng/"
"searxng/fa/>\n"
"Language: fa_IR\n"
"Language-Team: Persian "
"<https://translate.codeberg.org/projects/searxng/searxng/fa/>\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
"X-Generator: Weblate 5.6.2\n"
"Generated-By: Babel 2.15.0\n"
#. CONSTANT_NAMES['NO_SUBGROUPING']
@ -79,7 +80,7 @@ msgstr "رادیو"
#. CATEGORY_NAMES['TV']
#: searx/searxng.msg
msgid "tv"
msgstr ""
msgstr "تلویزیون"
#. CATEGORY_NAMES['IT']
#: searx/searxng.msg
@ -1940,4 +1941,3 @@ msgstr "پنهان‌سازی ویدئو"
#~ msgid "TiB"
#~ msgstr "ترابایت"

View file

@ -17,8 +17,8 @@ msgstr ""
"Project-Id-Version: searx\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-06-17 12:15+0000\n"
"PO-Revision-Date: 2024-07-06 16:18+0000\n"
"Last-Translator: jonkke9 <jonkke9@users.noreply.translate.codeberg.org>\n"
"PO-Revision-Date: 2024-07-19 07:09+0000\n"
"Last-Translator: return42 <return42@users.noreply.translate.codeberg.org>\n"
"Language-Team: Finnish <https://translate.codeberg.org/projects/searxng/"
"searxng/fi/>\n"
"Language: fi\n"
@ -327,7 +327,7 @@ msgstr "suljettu"
#. SOCIAL_MEDIA_TERMS['THREAD ANSWERED']
#: searx/engines/discourse.py:132 searx/searxng.msg
msgid "answered"
msgstr ""
msgstr "vastattu"
#: searx/webapp.py:330
msgid "No item found"

View file

@ -16,7 +16,7 @@ msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-06-17 12:15+0000\n"
"PO-Revision-Date: 2024-07-11 16:18+0000\n"
"PO-Revision-Date: 2024-07-19 07:09+0000\n"
"Last-Translator: wazhanudin <wazhanudin@users.noreply.translate.codeberg.org>"
"\n"
"Language-Team: Malay <https://translate.codeberg.org/projects/searxng/"
@ -697,14 +697,15 @@ msgstr "Sila semak untuk bug yang sedia ada tentang enjin ini di Github"
#: searx/templates/simple/new_issue.html:69
msgid "I confirm there is no existing bug about the issue I encounter"
msgstr ""
"Saya mengesahkan tiada pepijat yang sedia ada mengenai isu yang saya hadapi"
#: searx/templates/simple/new_issue.html:71
msgid "If this is a public instance, please specify the URL in the bug report"
msgstr ""
msgstr "Jika ini adalah contoh awam, sila nyatakan URL dalam laporan pepijat"
#: searx/templates/simple/new_issue.html:72
msgid "Submit a new issue on Github including the above information"
msgstr ""
msgstr "Hantar isu baru di Github termasuk maklumat di atas"
#: searx/templates/simple/preferences.html:65
msgid "No HTTPS"
@ -714,7 +715,7 @@ msgstr "Tanpa HTTPS"
#: searx/templates/simple/preferences.html:69
#: searx/templates/simple/preferences.html:70
msgid "View error logs and submit a bug report"
msgstr ""
msgstr "Paparkan log ralat dan hantar laporan pepijat"
#: searx/templates/simple/preferences.html:74
msgid "!bang for this engine"
@ -904,11 +905,11 @@ msgstr "Kod"
#: searx/templates/simple/stats.html:128
msgid "Checker"
msgstr ""
msgstr "Pemeriksa"
#: searx/templates/simple/stats.html:131
msgid "Failed test"
msgstr ""
msgstr "Ujian gagal"
#: searx/templates/simple/stats.html:132
msgid "Comment(s)"
@ -916,11 +917,11 @@ msgstr "Ulasan"
#: searx/templates/simple/elements/apis.html:3
msgid "Download results"
msgstr ""
msgstr "Keputusan muat turun"
#: searx/templates/simple/elements/engines_msg.html:7
msgid "Messages from the search engines"
msgstr ""
msgstr "Mesej dari enjin carian"
#: searx/templates/simple/elements/engines_msg.html:12
msgid "Error!"
@ -928,16 +929,16 @@ msgstr "Ralat!"
#: searx/templates/simple/elements/engines_msg.html:13
msgid "Engines cannot retrieve results"
msgstr ""
msgstr "Enjin tidak dapat mendapatkan keputusan"
#: searx/templates/simple/elements/search_url.html:3
msgid "Search URL"
msgstr ""
msgstr "URL Carian"
#: searx/templates/simple/elements/search_url.html:4
#: searx/templates/simple/preferences/cookies.html:54
msgid "Copied"
msgstr ""
msgstr "Disalin"
#: searx/templates/simple/elements/search_url.html:4
#: searx/templates/simple/preferences/cookies.html:54
@ -951,17 +952,17 @@ msgstr "Cadangan"
#: searx/templates/simple/filters/languages.html:1
#: searx/templates/simple/preferences/language.html:2
msgid "Search language"
msgstr ""
msgstr "Bahasa carian"
#: searx/templates/simple/filters/languages.html:2
#: searx/templates/simple/preferences/language.html:7
msgid "Default language"
msgstr ""
msgstr "Bahasa lalai"
#: searx/templates/simple/filters/languages.html:4
#: searx/templates/simple/preferences/language.html:11
msgid "Auto-detect"
msgstr ""
msgstr "Kesan secara automatik"
#: searx/templates/simple/filters/safesearch.html:1
#: searx/templates/simple/filters/safesearch.html:2
@ -970,7 +971,7 @@ msgstr ""
#: searx/templates/simple/preferences/engines.html:27
#: searx/templates/simple/preferences/safesearch.html:2
msgid "SafeSearch"
msgstr ""
msgstr "Carian Selamat"
#: searx/templates/simple/filters/safesearch.html:2
#: searx/templates/simple/preferences/safesearch.html:7
@ -990,7 +991,7 @@ msgstr "Tanpa"
#: searx/templates/simple/filters/time_range.html:1
#: searx/templates/simple/preferences/engines.html:28
msgid "Time range"
msgstr ""
msgstr "Julat masa"
#: searx/templates/simple/filters/time_range.html:3
msgid "Anytime"
@ -1018,7 +1019,7 @@ msgstr "Informasi!"
#: searx/templates/simple/messages/no_cookies.html:4
msgid "currently, there are no cookies defined."
msgstr ""
msgstr "pada masa ini, tiada kuki yang ditakrifkan."
#: searx/templates/simple/messages/no_results.html:6
msgid "Sorry!"
@ -1026,35 +1027,35 @@ msgstr "Harap maaf!"
#: searx/templates/simple/messages/no_results.html:12
msgid "No results were found. You can try to:"
msgstr ""
msgstr "Tiada keputusan ditemui. Anda boleh cuba untuk:"
#: searx/templates/simple/messages/no_results.html:14
msgid "There are no more results. You can try to:"
msgstr ""
msgstr "Tiada lagi keputusan. Anda boleh cuba untuk:"
#: searx/templates/simple/messages/no_results.html:19
msgid "Refresh the page."
msgstr ""
msgstr "Segar semula halaman."
#: searx/templates/simple/messages/no_results.html:20
msgid "Search for another query or select another category (above)."
msgstr ""
msgstr "Cari pertanyaan lain atau pilih kategori lain (di atas)."
#: searx/templates/simple/messages/no_results.html:21
msgid "Change the search engine used in the preferences:"
msgstr ""
msgstr "Tukar enjin carian yang digunakan dalam tetapan:"
#: searx/templates/simple/messages/no_results.html:22
msgid "Switch to another instance:"
msgstr ""
msgstr "Tukar ke contoh lain:"
#: searx/templates/simple/messages/no_results.html:24
msgid "Search for another query or select another category."
msgstr ""
msgstr "Cari pertanyaan lain atau pilih kategori lain."
#: searx/templates/simple/messages/no_results.html:25
msgid "Go back to the previous page using the previous page button."
msgstr ""
msgstr "Kembali ke halaman sebelumnya menggunakan butang halaman sebelumnya."
#: searx/templates/simple/preferences/answerers.html:4
#: searx/templates/simple/preferences/engines.html:23
@ -1080,33 +1081,35 @@ msgstr "Contoh-contoh"
#: searx/templates/simple/preferences/answerers.html:13
msgid "This is the list of SearXNG's instant answering modules."
msgstr ""
msgstr "Ini adalah senarai modul jawapan segera SearXNG."
#: searx/templates/simple/preferences/answerers.html:29
msgid "This is the list of plugins."
msgstr ""
msgstr "Ini adalah senarai plugin."
#: searx/templates/simple/preferences/autocomplete.html:2
msgid "Autocomplete"
msgstr ""
msgstr "Lengkap secara automatik"
#: searx/templates/simple/preferences/autocomplete.html:15
msgid "Find stuff as you type"
msgstr ""
msgstr "Cari perkara semasa anda menaip"
#: searx/templates/simple/preferences/center_alignment.html:2
msgid "Center Alignment"
msgstr ""
msgstr "Penyelarasan Tengah"
#: searx/templates/simple/preferences/center_alignment.html:14
msgid "Displays results in the center of the page (Oscar layout)."
msgstr ""
msgstr "Memaparkan keputusan di tengah halaman (susun atur Oscar)."
#: searx/templates/simple/preferences/cookies.html:2
msgid ""
"This is the list of cookies and their values SearXNG is storing on your "
"computer."
msgstr ""
"Ini adalah senarai kuki dan nilai-nilainya yang disimpan oleh SearXNG pada "
"komputer anda."
#: searx/templates/simple/preferences/cookies.html:3
msgid "With that list, you can assess SearXNG transparency."
@ -1114,7 +1117,7 @@ msgstr "Dengan senarai itu, anda boleh menilai ketelusan SearXNG."
#: searx/templates/simple/preferences/cookies.html:9
msgid "Cookie name"
msgstr ""
msgstr "Nama kuki"
#: searx/templates/simple/preferences/cookies.html:10
msgid "Value"
@ -1122,13 +1125,15 @@ msgstr "Nilai"
#: searx/templates/simple/preferences/cookies.html:23
msgid "Search URL of the currently saved preferences"
msgstr ""
msgstr "URL carian bagi tetapan yang disimpan pada masa ini"
#: searx/templates/simple/preferences/cookies.html:32
msgid ""
"Note: specifying custom settings in the search URL can reduce privacy by "
"leaking data to the clicked result sites."
msgstr ""
"Nota: menentukan tetapan khusus dalam URL carian boleh mengurangkan privasi "
"dengan membocorkan data kepada laman hasil yang diklik."
#: searx/templates/simple/preferences/cookies.html:35
msgid "URL to restore your preferences in another browser"
@ -1139,6 +1144,8 @@ msgid ""
"Specifying custom settings in the preferences URL can be used to sync "
"preferences across devices."
msgstr ""
"Menentukan tetapan khusus dalam URL tetapan boleh digunakan untuk "
"menyegerakkan tetapan merentasi peranti."
#: searx/templates/simple/preferences/cookies.html:46
msgid "Copy preferences hash"
@ -1357,7 +1364,7 @@ msgstr ""
#: searx/templates/simple/result_templates/files.html:42
#: searx/templates/simple/result_templates/paper.html:24
msgid "Type"
msgstr ""
msgstr "Jenis"
#: searx/templates/simple/result_templates/images.html:20
msgid "Resolution"
@ -1373,7 +1380,7 @@ msgstr "Enjin"
#: searx/templates/simple/result_templates/images.html:25
msgid "View source"
msgstr ""
msgstr "Lihat sumber"
#: searx/templates/simple/result_templates/map.html:12
msgid "address"
@ -1389,15 +1396,15 @@ msgstr "sembunyikan peta"
#: searx/templates/simple/result_templates/packages.html:12
msgid "Version"
msgstr ""
msgstr "Versi"
#: searx/templates/simple/result_templates/packages.html:18
msgid "Maintainer"
msgstr ""
msgstr "Penyelenggara"
#: searx/templates/simple/result_templates/packages.html:24
msgid "Updated at"
msgstr ""
msgstr "Dikemaskini pada"
#: searx/templates/simple/result_templates/packages.html:30
#: searx/templates/simple/result_templates/paper.html:25
@ -1406,7 +1413,7 @@ msgstr "Tag"
#: searx/templates/simple/result_templates/packages.html:36
msgid "Popularity"
msgstr ""
msgstr "Kepopularan"
#: searx/templates/simple/result_templates/packages.html:42
msgid "License"
@ -1414,11 +1421,11 @@ msgstr "Lesen"
#: searx/templates/simple/result_templates/packages.html:52
msgid "Project"
msgstr ""
msgstr "Projek"
#: searx/templates/simple/result_templates/packages.html:55
msgid "Project homepage"
msgstr ""
msgstr "Halaman utama projek"
#: searx/templates/simple/result_templates/paper.html:5
msgid "Published date"
@ -1426,15 +1433,15 @@ msgstr "Tarikh diterbitkan"
#: searx/templates/simple/result_templates/paper.html:9
msgid "Journal"
msgstr ""
msgstr "Jurnal"
#: searx/templates/simple/result_templates/paper.html:22
msgid "Editor"
msgstr ""
msgstr "Penyunting"
#: searx/templates/simple/result_templates/paper.html:23
msgid "Publisher"
msgstr ""
msgstr "Penerbit"
#: searx/templates/simple/result_templates/paper.html:26
msgid "DOI"
@ -1462,19 +1469,19 @@ msgstr "pautan magnet"
#: searx/templates/simple/result_templates/torrent.html:7
msgid "torrent file"
msgstr ""
msgstr "fail torrent"
#: searx/templates/simple/result_templates/torrent.html:9
msgid "Seeder"
msgstr ""
msgstr "Pembenih"
#: searx/templates/simple/result_templates/torrent.html:9
msgid "Leecher"
msgstr ""
msgstr "Pengambil"
#: searx/templates/simple/result_templates/torrent.html:13
msgid "Number of Files"
msgstr ""
msgstr "Bilangan Fail"
#: searx/templates/simple/result_templates/videos.html:6
msgid "show video"

View file

@ -23,13 +23,14 @@
# morenewsavailable
# <morenewsavailable@users.noreply.translate.codeberg.org>, 2024.
# PeterDaveHello <PeterDaveHello@users.noreply.translate.codeberg.org>, 2024.
# pdwalker <pdwalker@users.noreply.translate.codeberg.org>, 2024.
msgid ""
msgstr ""
"Project-Id-Version: searx\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2024-06-17 12:15+0000\n"
"PO-Revision-Date: 2024-06-26 13:18+0000\n"
"Last-Translator: return42 <return42@users.noreply.translate.codeberg.org>\n"
"PO-Revision-Date: 2024-07-26 07:09+0000\n"
"Last-Translator: pdwalker <pdwalker@users.noreply.translate.codeberg.org>\n"
"Language-Team: Chinese (Traditional) <https://translate.codeberg.org/"
"projects/searxng/searxng/zh_Hant/>\n"
"Language: zh_Hant_TW\n"
@ -37,7 +38,7 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Weblate 5.5.5\n"
"X-Generator: Weblate 5.6.2\n"
"Generated-By: Babel 2.15.0\n"
#. CONSTANT_NAMES['NO_SUBGROUPING']
@ -223,7 +224,7 @@ msgstr "溼度"
#. WEATHER_TERMS['MAX TEMP.']
#: searx/searxng.msg
msgid "Max temp."
msgstr "最高溫"
msgstr "最高溫"
#. WEATHER_TERMS['MIN TEMP.']
#: searx/searxng.msg

View file

@ -44,16 +44,6 @@ _JS_QUOTE_KEYS_RE = re.compile(r'([\{\s,])(\w+)(:)')
_JS_VOID_RE = re.compile(r'void\s+[0-9]+|void\s*\([0-9]+\)')
_JS_DECIMAL_RE = re.compile(r":\s*\.")
_STORAGE_UNIT_VALUE: Dict[str, int] = {
'TB': 1024 * 1024 * 1024 * 1024,
'GB': 1024 * 1024 * 1024,
'MB': 1024 * 1024,
'TiB': 1000 * 1000 * 1000 * 1000,
'GiB': 1000 * 1000 * 1000,
'MiB': 1000 * 1000,
'KiB': 1000,
}
_XPATH_CACHE: Dict[str, XPath] = {}
_LANG_TO_LC_CACHE: Dict[str, Dict[str, str]] = {}
@ -344,6 +334,18 @@ def humanize_bytes(size, precision=2):
return "%.*f %s" % (precision, size, s[p])
def humanize_number(size, precision=0):
"""Determine the *human readable* value of a decimal number."""
s = ['', 'K', 'M', 'B', 'T']
x = len(s)
p = 0
while size > 1000 and p < x:
p += 1
size = size / 1000.0
return "%.*f%s" % (precision, size, s[p])
def convert_str_to_int(number_str: str) -> int:
"""Convert number_str to int or 0 if number_str is not a number."""
if number_str.isdigit():