Skip to content

Commit 0ac4e71

Browse files
committed
Refined update instances script. Bump version => 1.6.3
1 parent c86cc93 commit 0ac4e71

File tree

5 files changed

+28
-24
lines changed

5 files changed

+28
-24
lines changed

chromium.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
### Install in Chromium, Brave and Chrome
2-
- Download the lastest release [libredirect-1.6.2.zip](https://github.com/libredirect/libredirect/releases/download/v1.6.2/libredirect-1.6.2.zip)
2+
- Download the lastest release [libredirect-1.6.3.zip](https://github.com/libredirect/libredirect/releases/download/v1.6.3/libredirect-1.6.3.zip)
33
- Unzip it with `Auto detect subfolder`
44
- Open `chrome://extensions`
55
- Enable `dev mode`
6-
- Click `Load unpacked`. Select and Open `libredirect-1.6.2/`
6+
- Click `Load unpacked`. Select and Open `libredirect-1.6.3/`
77
Updates are automatic
88

99
https://user-images.githubusercontent.com/40805353/159987051-8be73cd3-3fdf-4dd0-99d4-8886674fbdb6.mp4

src/instances/data.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,6 +347,7 @@
347347
"https://searx.dresden.network",
348348
"https://searx.everdot.org",
349349
"https://searx.fossencdi.org",
350+
"https://searx.gnous.eu",
350351
"https://searx.gnu.style",
351352
"https://searx.hardwired.link",
352353
"https://searx.josie.lol",
@@ -417,7 +418,6 @@
417418
"https://searx.ebnar.xyz",
418419
"https://searx.esmailelbob.xyz",
419420
"https://searx.fmac.xyz",
420-
"https://searx.gnous.eu",
421421
"https://searx.mha.fi",
422422
"https://searx.namejeff.xyz",
423423
"https://searx.prvcy.eu",

src/instances/get_instances.py

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@
99

1010
mightyList = {}
1111

12+
1213
def filterLastSlash(urlList):
1314
tmp = []
1415
for i in urlList:
1516
if i.endswith('/'):
1617
tmp.append(i[:-1])
17-
print(Fore.YELLOW + "filtered " + Style.RESET_ALL + i)
18+
print(Fore.YELLOW + "Fixed " + Style.RESET_ALL + i)
1819
else:
1920
tmp.append(i)
2021
return tmp
@@ -32,10 +33,11 @@ def filterLastSlash(urlList):
3233
elif instance[1]['type'] == 'onion':
3334
invidiousList['tor'].append(instance[1]['uri'])
3435
mightyList['invidious'] = invidiousList
35-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Invidious')
36+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Invidious')
3637

3738
# ProxiTok
38-
r = requests.get('https://raw.githubusercontent.com/wiki/pablouser1/ProxiTok/Public-instances.md')
39+
r = requests.get(
40+
'https://raw.githubusercontent.com/wiki/pablouser1/ProxiTok/Public-instances.md')
3941

4042
tmp = re.findall(
4143
r"\| \[.*\]\(([-a-zA-Z0-9@:%_\+.~#?&//=]{2,}\.[a-z]{2,}\b(?:\/[-a-zA-Z0-9@:%_\+.~#?&//=]*)?)\)*\|*[A-Z]{0,}.*\|.*\|", r.text)
@@ -45,18 +47,20 @@ def filterLastSlash(urlList):
4547
for item in tmp:
4648
proxiTokList['normal'].append(item)
4749
mightyList['proxiTok'] = proxiTokList
48-
print('fetched ProxiTok')
50+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'ProxiTok')
4951

5052
# Send
51-
r = requests.get('https://gitlab.com/timvisee/send-instances/-/raw/master/README.md')
52-
tmp = re.findall(r"- ([-a-zA-Z0-9@:%_\+.~#?&//=]{2,}\.[a-z0-9]{2,}\b(?:\/[-a-zA-Z0-9@:%_\+.~#?&//=]*)?)\)*\|*[A-Z]{0,}", r.text)
53+
r = requests.get(
54+
'https://gitlab.com/timvisee/send-instances/-/raw/master/README.md')
55+
tmp = re.findall(
56+
r"- ([-a-zA-Z0-9@:%_\+.~#?&//=]{2,}\.[a-z0-9]{2,}\b(?:\/[-a-zA-Z0-9@:%_\+.~#?&//=]*)?)\)*\|*[A-Z]{0,}", r.text)
5357
sendList = {}
5458
sendList['normal'] = []
5559
sendList['tor'] = []
5660
for item in tmp:
5761
sendList['normal'].append(item)
5862
mightyList['send'] = sendList
59-
print(Fore.GREEN +'fetched ' + Style.RESET_ALL + 'Send')
63+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Send')
6064

6165
# Nitter
6266
r = requests.get('https://github.com/zedeus/nitter/wiki/Instances')
@@ -82,7 +86,7 @@ def filterLastSlash(urlList):
8286
url = 'https://' + url
8387
nitterList['normal'].append(url)
8488
mightyList['nitter'] = nitterList
85-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Nitter')
89+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Nitter')
8690

8791
# Bibliogram
8892
r = requests.get('https://bibliogram.pussthecat.org/api/instances')
@@ -93,7 +97,7 @@ def filterLastSlash(urlList):
9397
for item in rJson['data']:
9498
bibliogramList['normal'].append(item['address'])
9599
mightyList['bibliogram'] = bibliogramList
96-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Bibliogram')
100+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Bibliogram')
97101

98102
# LibReddit
99103
r = requests.get(
@@ -113,7 +117,7 @@ def filterLastSlash(urlList):
113117
else:
114118
libredditList['normal'].append(item)
115119
mightyList['libreddit'] = libredditList
116-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'LibReddit')
120+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'LibReddit')
117121

118122
# Teddit
119123
r = requests.get(
@@ -132,7 +136,7 @@ def filterLastSlash(urlList):
132136
tedditList['tor'].append(onion)
133137

134138
mightyList['teddit'] = tedditList
135-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Teddit')
139+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Teddit')
136140

137141

138142
# Wikiless
@@ -150,7 +154,7 @@ def filterLastSlash(urlList):
150154
else:
151155
wikilessList['normal'].append('https://' + item)
152156
mightyList['wikiless'] = wikilessList
153-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Wikiless')
157+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Wikiless')
154158

155159
# Scribe
156160
r = requests.get(
@@ -162,7 +166,7 @@ def filterLastSlash(urlList):
162166
for item in rJson:
163167
scribeList['normal'].append(item)
164168
mightyList['scribe'] = scribeList
165-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Scribe')
169+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Scribe')
166170

167171
# SimplyTranslate
168172
r = requests.get('https://simple-web.org/instances/simplytranslate')
@@ -177,7 +181,7 @@ def filterLastSlash(urlList):
177181
simplyTranslateList['tor'].append('http://' + item)
178182

179183
mightyList['simplyTranslate'] = simplyTranslateList
180-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'SimplyTranslate')
184+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'SimplyTranslate')
181185

182186
# LinvgaTranslate
183187
r = requests.get(
@@ -189,7 +193,7 @@ def filterLastSlash(urlList):
189193
for item in rJson:
190194
lingvaList['normal'].append(item)
191195
mightyList['lingva'] = lingvaList
192-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'LinvgaTranslate')
196+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'LinvgaTranslate')
193197

194198

195199
# SearX, SearXNG
@@ -222,7 +226,7 @@ def filterLastSlash(urlList):
222226

223227
mightyList['searx'] = searxList
224228
mightyList['searxng'] = searxngList
225-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'SearX, SearXNG')
229+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'SearX, SearXNG')
226230

227231
# Whoogle
228232
r = requests.get(
@@ -240,7 +244,7 @@ def filterLastSlash(urlList):
240244
else:
241245
whoogleList['normal'].append(item)
242246
mightyList['whoogle'] = whoogleList
243-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Whoogle')
247+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Whoogle')
244248

245249
# Rimgo
246250
r = requests.get(
@@ -258,7 +262,7 @@ def filterLastSlash(urlList):
258262
else:
259263
rimgoList['normal'].append('https://' + item)
260264
mightyList['rimgo'] = rimgoList
261-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Rimgo')
265+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Rimgo')
262266

263267
# Peertube
264268
r = requests.get(
@@ -270,7 +274,7 @@ def filterLastSlash(urlList):
270274
myList.append('https://'+k['host'])
271275

272276
mightyList['peertube'] = myList
273-
print(Fore.GREEN + 'fetched ' + Style.RESET_ALL + 'Peertube')
277+
print(Fore.GREEN + 'Fetched ' + Style.RESET_ALL + 'Peertube')
274278

275279

276280
def isValid(url): # This code is contributed by avanitrachhadiya2155

src/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "__MSG_extensionName__",
33
"description": "__MSG_extensionDescription__",
4-
"version": "1.6.2",
4+
"version": "1.6.3",
55
"manifest_version": 2,
66
"browser_specific_settings": {
77
"gecko": {

src/updates/updates.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version='1.0' encoding='UTF-8'?>
22
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
33
<app appid='oladmjdebphlnjjcnomfhhbfdldiimaf'>
4-
<updatecheck codebase='https://github.com/libredirect/libredirect/releases/download/v1.6.1/libredirect-1.6.2.crx' version='1.6.2' />
4+
<updatecheck codebase='https://github.com/libredirect/libredirect/releases/download/v1.6.1/libredirect-1.6.3.crx' version='1.6.3' />
55
</app>
66
</gupdate>

0 commit comments

Comments
 (0)