Skip to content
Snippets Groups Projects
Commit 5d502192 authored by Frede H's avatar Frede H :speech_balloon:
Browse files

Merge remote-tracking branch 'upstream/master' (reverted from commit...

Merge remote-tracking branch 'upstream/master' (reverted from commit 9df3c6ec)
parent 63f3b65a
No related branches found
No related tags found
No related merge requests found
...@@ -2,10 +2,8 @@ ...@@ -2,10 +2,8 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
## [4.0.4-dev] ## [4.0.4-dev]
- Improvement on `--interactive`: select mirrors by protocol. - improvement on `--interactive`: select mirrors by protocol
- Added to config `# SSL = False`. - added to config `# SSL = False`
- Some optimizations.
- Update translations.
## [4.0.3] - 2017-03-28 ## [4.0.3] - 2017-03-28
- Fix issue with `--fasttrack` and `OnlyCountry = Custom`. - Fix issue with `--fasttrack` and `OnlyCountry = Custom`.
......
...@@ -9,7 +9,7 @@ help: ...@@ -9,7 +9,7 @@ help:
@echo "test - run tests quickly with the default Python" @echo "test - run tests quickly with the default Python"
@echo "test-all - run tests on every Python version with tox" @echo "test-all - run tests on every Python version with tox"
@echo "coverage - check code coverage quickly with the default Python" @echo "coverage - check code coverage quickly with the default Python"
@echo "docs - generate MkDocs HTML documentation, including API docs" @echo "docs - generate Sphinx HTML documentation, including API docs"
@echo "release - package and upload a release" @echo "release - package and upload a release"
@echo "dist - package" @echo "dist - package"
@echo "install - install the package to the active Python's site-packages" @echo "install - install the package to the active Python's site-packages"
......
...@@ -17,31 +17,27 @@ Package that provides all mirrors for Manjaro Linux. ...@@ -17,31 +17,27 @@ Package that provides all mirrors for Manjaro Linux.
- A GUI for selecting the mirrors to used to generate a custom list. - A GUI for selecting the mirrors to used to generate a custom list.
### How does fasttrack work ### How does fasttrack work
First of all, a working internet connection is mandatory. pacman-mirrors always checks if network is online. It is doing so by pinging google with 3 packets. First of all, a working internet connection is mandatory. Pacman-Mirrors always checks if network is online. It is doing so by pinging google with 3 packets.
The following arguments `-c -i -m --geoip` will not work in conjunction with `-f`. The following arguments `-c -i -m --geoip` will not work in conjunction with `-f`.
#### Question: #### Question:
So, `pacman-mirrors -f 2` takes the same time to create `/etc/pacman.d/mirrorlist` as `pacman-mirrors -f 20`? So, `pacman-mirrors -f 2` takes the same time to create `/etc/pacman.d/mirrorlist` as `pacman-mirrors -f 20`?
##### Answer: ##### Answer:
No. `pacman-mirors -f 2` will be faster than `pacman-mirrors -f 20` since only 2 mirrors are probed vs 20 mirrors but since most mirrors respond within the first second it is barely noticeable. No. `pacman-mirors -f 2` will be faster than `pacman-mirrors -f 20` since only 2 mirrors are probed vs 20 mirrors but since most mirrors respond within the first second it is barely noticeable.
#### Question: #### Question:
`pacman-mirrors -f n` always ranks ALL mirrors by response time (the same as `pacman-mirrors -g` does) and additionally takes up-to-date mirrors and writes only **n** mirrors to `/etc/pacman.d/mirrorlist`? `pacman-mirrors -f n` always ranks ALL mirrors by response time (the same as `pacman-mirrors -g` does) and additionally takes up-to-date mirrors and writes only **n** mirrors to `/etc/pacman.d/mirrorlist`?
##### Answer: ##### Answer:
No. `pacman-mirrors -f n` ranks on a sorted list with known up-to-date mirrors. Thus it is only the first **n** mirrors from this list which are actually probed. If you have a list of 30 mirrors which are up-to-date and use `-f 5` only the top 5 mirrors are probed and then sorted after response time. No. `pacman-mirrors -f n` ranks on a sorted list with known up-to-date mirrors. Thus it is only the first **n** mirrors from this list which are actually probed. If you have a list of 30 mirrors which are uptodate and use `-f 5` only the top 5 mirrors are probed and then sorted after response time.
The switch does not guarantee you get **the n** fastest mirrors only that they are responsive and up-to-date. Mirrors which have network errors or times out are not considered at all. The switch does not guarantee you get **the n** fastest mirrors only that they are responsive and uptodate. Mirrors which have network errors or times out are not considered at all.
#### Beware #### Beware
The smaller number you choose to write to the mirrorlist will increase the possibility of not getting a responsive mirror since only the first **n** in the list are tested not all of them. The smaller number you choose to write to the mirrorlist will increase the possibility of not getting a responsive mirror since only the first **n** in the list are tested not all of them.
A reasonable number is between 5 and 10. A reasonable number is between 5 and 10.
The force of this approach is that we know forehand if the mirror is up-to-date and thus only have to rank **n** mirrors from the mirrors known to be up-to-date. The force of this approach is that we know forehand if the mirror is uptodate and thus only have to rank **n** mirrors from the mirrors known to be uptodate.
If you need a complete ranking then `pacman-mirrors -g` is the way to go. If you need a complete ranking then `pacman-mirrors -g` is the way to go.
## Technologies ## Technologies
pacman-mirrors uses open-source projects to work properly: pacman-mirrors is build with Python and Gtk3.
* [Python 3](https://www.python.org)
* [GTK+ 3](https://www.gtk.org)
* [npyscreen](https://github.com/npcole/npyscreen)
...@@ -5,16 +5,14 @@ ...@@ -5,16 +5,14 @@
# #
# Translators: # Translators:
# Ali Kömesöğütlü <byzlo685@gmail.com>, 2017 # Ali Kömesöğütlü <byzlo685@gmail.com>, 2017
# Demiray Muhterem <mdemiray@msn.com>, 2017
# ilkeryus <ilkeryus@gmail.com>, 2016
# ilkeryus <ilkeryus@gmail.com>, 2016 # ilkeryus <ilkeryus@gmail.com>, 2016
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: manjaro-pacman-mirrors\n" "Project-Id-Version: manjaro-pacman-mirrors\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
"POT-Creation-Date: 2017-02-20 15:44+0100\n" "POT-Creation-Date: 2017-02-20 15:44+0100\n"
"PO-Revision-Date: 2017-03-30 19:10+0000\n" "PO-Revision-Date: 2017-03-06 15:24+0000\n"
"Last-Translator: Demiray Muhterem <mdemiray@msn.com>\n" "Last-Translator: Ali Kömesöğütlü <byzlo685@gmail.com>\n"
"Language-Team: Turkish (http://www.transifex.com/manjarolinux/manjaro-pacman-mirrors/language/tr/)\n" "Language-Team: Turkish (http://www.transifex.com/manjarolinux/manjaro-pacman-mirrors/language/tr/)\n"
"MIME-Version: 1.0\n" "MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n" "Content-Type: text/plain; charset=UTF-8\n"
...@@ -41,7 +39,7 @@ msgstr "Zaman aşımı" ...@@ -41,7 +39,7 @@ msgstr "Zaman aşımı"
#: pacman_mirrors/txt.py:36 #: pacman_mirrors/txt.py:36
msgid "HTTPException" msgid "HTTPException"
msgstr "HTTPHariç" msgstr ""
#: pacman_mirrors/txt.py:38 #: pacman_mirrors/txt.py:38
msgid "PATH" msgid "PATH"
...@@ -57,115 +55,115 @@ msgstr "SANİYE" ...@@ -57,115 +55,115 @@ msgstr "SANİYE"
#: pacman_mirrors/txt.py:41 #: pacman_mirrors/txt.py:41
msgid "DIGIT" msgid "DIGIT"
msgstr "RAKAM" msgstr ""
#: pacman_mirrors/txt.py:43 #: pacman_mirrors/txt.py:43
msgid "Branch name" msgid "Branch name"
msgstr "Kol adı" msgstr ""
#: pacman_mirrors/txt.py:44 #: pacman_mirrors/txt.py:44
msgid "Comma separated list of countries, from which mirrors will be used" msgid "Comma separated list of countries, from which mirrors will be used"
msgstr "Yansıların kullanılacağı, virgülle ayrılmış ülkelerin listesi" msgstr ""
#: pacman_mirrors/txt.py:46 #: pacman_mirrors/txt.py:46
msgid "Output file" msgid "Output file"
msgstr "Çıktı dosyası" msgstr ""
#: pacman_mirrors/txt.py:47 #: pacman_mirrors/txt.py:47
msgid "Generate mirrorlist" msgid "Generate mirrorlist"
msgstr "Yansı listesi oluştur" msgstr ""
#: pacman_mirrors/txt.py:48 #: pacman_mirrors/txt.py:48
msgid "Get current country using geolocation. Ignored if" msgid "Get current country using geolocation. Ignored if"
msgstr "Coğrafi konum kullanarak ülkenizi öğrenin. Yok sayarsan" msgstr ""
#: pacman_mirrors/txt.py:49 #: pacman_mirrors/txt.py:49
msgid "is supplied" msgid "is supplied"
msgstr "tedarik edildi" msgstr ""
#: pacman_mirrors/txt.py:50 #: pacman_mirrors/txt.py:50
msgid "Generate custom mirrorlist" msgid "Generate custom mirrorlist"
msgstr "Özel yansı listesi oluştur" msgstr ""
#: pacman_mirrors/txt.py:51 #: pacman_mirrors/txt.py:51
msgid "Generation method" msgid "Generation method"
msgstr "Oluşturma yöntemi" msgstr ""
#: pacman_mirrors/txt.py:52 #: pacman_mirrors/txt.py:52
msgid "Don't generate mirrorlist if" msgid "Don't generate mirrorlist if"
msgstr "Eğer var ise yansı listesi oluşturmayın" msgstr ""
#: pacman_mirrors/txt.py:53 #: pacman_mirrors/txt.py:53
msgid "in the configuration file" msgid "in the configuration file"
msgstr "yapılandırma dosyasında" msgstr ""
#: pacman_mirrors/txt.py:54 #: pacman_mirrors/txt.py:54
msgid "Mirrors list path" msgid "Mirrors list path"
msgstr "yansı listesi yolu" msgstr ""
#: pacman_mirrors/txt.py:55 #: pacman_mirrors/txt.py:55
msgid "Quiet mode - less verbose output" msgid "Quiet mode - less verbose output"
msgstr "Sessiz mod - daha detaysız çıktı" msgstr ""
#: pacman_mirrors/txt.py:56 #: pacman_mirrors/txt.py:56
msgid "Maximum waiting time for server response" msgid "Maximum waiting time for server response"
msgstr "Sunucu yanıtı için azami bekleme süresi" msgstr ""
#: pacman_mirrors/txt.py:57 #: pacman_mirrors/txt.py:57
msgid "Print the pacman-mirrors version" msgid "Print the pacman-mirrors version"
msgstr "pacman-mirrors sürümünü yazdır" msgstr ""
#: pacman_mirrors/txt.py:58 #: pacman_mirrors/txt.py:58
msgid "A quick mirrorlist. Overrides -cim --geoip" msgid "A quick mirrorlist. Overrides -cim --geoip"
msgstr "Hızlı bir yansı listesi. -cim --geoip'i geçersiz kılar" msgstr ""
#: pacman_mirrors/txt.py:60 #: pacman_mirrors/txt.py:60
msgid "Available countries are" msgid "Available countries are"
msgstr "Mevcut ülkeler" msgstr ""
#: pacman_mirrors/txt.py:61 #: pacman_mirrors/txt.py:61
msgid "Could not download from" msgid "Could not download from"
msgstr "Adresinden indirilemedi" msgstr ""
#: pacman_mirrors/txt.py:62 #: pacman_mirrors/txt.py:62
msgid "Cannot read file" msgid "Cannot read file"
msgstr "Dosya okunamadı" msgstr ""
#: pacman_mirrors/txt.py:63 #: pacman_mirrors/txt.py:63
msgid "Cannot write file" msgid "Cannot write file"
msgstr "Dosyaya yazılamadı" msgstr ""
#: pacman_mirrors/txt.py:64 #: pacman_mirrors/txt.py:64
msgid "Converting custom mirror file to new format" msgid "Converting custom mirror file to new format"
msgstr "Özel yansı listesini yeni biçime dönüştür" msgstr ""
#: pacman_mirrors/txt.py:65 #: pacman_mirrors/txt.py:65
msgid "Custom mirror file" msgid "Custom mirror file"
msgstr "Özel yansı dosyası" msgstr ""
#: pacman_mirrors/txt.py:66 #: pacman_mirrors/txt.py:66
msgid "Custom mirror file saved" msgid "Custom mirror file saved"
msgstr "Özel yansı dpsyası kaydedildi" msgstr ""
#: pacman_mirrors/txt.py:67 #: pacman_mirrors/txt.py:67
msgid "User generated mirror list" msgid "User generated mirror list"
msgstr "Kullanıcı tarafından oluşturulan yansı listesi" msgstr ""
#: pacman_mirrors/txt.py:68 #: pacman_mirrors/txt.py:68
msgid "doesn't exist." msgid "doesn't exist."
msgstr "varolmayan." msgstr ""
#: pacman_mirrors/txt.py:69 #: pacman_mirrors/txt.py:69
msgid "Downloading mirrors from repo.manjaro.org" msgid "Downloading mirrors from repo.manjaro.org"
msgstr "Yansı listesi repo.manjaro.org adresinden indiriliyor" msgstr ""
#: pacman_mirrors/txt.py:70 #: pacman_mirrors/txt.py:70
msgid "Falling back to" msgid "Falling back to"
msgstr "Geri düşüm" msgstr ""
#: pacman_mirrors/txt.py:71 #: pacman_mirrors/txt.py:71
msgid "is missing" msgid "is missing"
msgstr "kayıp" msgstr ""
#: pacman_mirrors/txt.py:72 #: pacman_mirrors/txt.py:72
msgid "The mirror file" msgid "The mirror file"
...@@ -173,19 +171,19 @@ msgstr "Yansı dosyası" ...@@ -173,19 +171,19 @@ msgstr "Yansı dosyası"
#: pacman_mirrors/txt.py:73 #: pacman_mirrors/txt.py:73
msgid "Mirrorlist generated and saved to" msgid "Mirrorlist generated and saved to"
msgstr "Yansı oluşturuldu ve kaydedildi" msgstr ""
#: pacman_mirrors/txt.py:74 #: pacman_mirrors/txt.py:74
msgid "Must have root privileges" msgid "Must have root privileges"
msgstr "Root yetkisine sahip olmalısınız" msgstr ""
#: pacman_mirrors/txt.py:75 #: pacman_mirrors/txt.py:75
msgid "The mirror list is not changed" msgid "The mirror list is not changed"
msgstr "Yansı listesi değiştirilmedi" msgstr ""
#: pacman_mirrors/txt.py:76 #: pacman_mirrors/txt.py:76
msgid "No mirrors in selection" msgid "No mirrors in selection"
msgstr "Yansı seçilmedi" msgstr ""
#: pacman_mirrors/txt.py:77 #: pacman_mirrors/txt.py:77
msgid "Option" msgid "Option"
...@@ -193,51 +191,51 @@ msgstr "Seçenek" ...@@ -193,51 +191,51 @@ msgstr "Seçenek"
#: pacman_mirrors/txt.py:78 #: pacman_mirrors/txt.py:78
msgid "Writing mirror list" msgid "Writing mirror list"
msgstr "Yansı listesi yazılıyor" msgstr ""
#: pacman_mirrors/txt.py:79 #: pacman_mirrors/txt.py:79
msgid "Querying mirrors" msgid "Querying mirrors"
msgstr "Yansı sorgulama" msgstr ""
#: pacman_mirrors/txt.py:80 #: pacman_mirrors/txt.py:80
msgid "Randomizing mirror list" msgid "Randomizing mirror list"
msgstr "Rastgele yansı listesi seç" msgstr ""
#: pacman_mirrors/txt.py:81 #: pacman_mirrors/txt.py:81
msgid "To reset custom config run `pacman-mirrors -c all`" msgid "To reset custom config run `pacman-mirrors -c all`"
msgstr "Özel yansıları sıfırlamak için `pacman-mirrors -c all` kullanın" msgstr ""
#: pacman_mirrors/txt.py:82 #: pacman_mirrors/txt.py:82
msgid "This may take some time" msgid "This may take some time"
msgstr "Bu işlem biraz zaman alabilir" msgstr ""
#: pacman_mirrors/txt.py:83 #: pacman_mirrors/txt.py:83
msgid "unknown country" msgid "unknown country"
msgstr "bilinmeyen ülke" msgstr ""
#: pacman_mirrors/txt.py:84 #: pacman_mirrors/txt.py:84
msgid "Using all mirrors" msgid "Using all mirrors"
msgstr "Tüm yansılar kullanılsın" msgstr ""
#: pacman_mirrors/txt.py:85 #: pacman_mirrors/txt.py:85
msgid "Using custom mirror file" msgid "Using custom mirror file"
msgstr "Özel yansı dosyası kullanılsın" msgstr ""
#: pacman_mirrors/txt.py:86 #: pacman_mirrors/txt.py:86
msgid "Using default mirror file" msgid "Using default mirror file"
msgstr "Varsayılan yansı dosyası kullanılsın" msgstr ""
#: pacman_mirrors/txt.py:88 #: pacman_mirrors/txt.py:88
msgid "Manjaro mirrors by response time" msgid "Manjaro mirrors by response time"
msgstr "Hızına göre yansılar kullanılsın" msgstr ""
#: pacman_mirrors/txt.py:89 #: pacman_mirrors/txt.py:89
msgid "Manjaro mirrors in random order" msgid "Manjaro mirrors in random order"
msgstr "Rastgele sıralanmış yansılar kullanılsın" msgstr ""
#: pacman_mirrors/txt.py:90 #: pacman_mirrors/txt.py:90
msgid "Check mirrors for your personal list" msgid "Check mirrors for your personal list"
msgstr "Özel listeniz için yansıları kontrol edin" msgstr ""
#: pacman_mirrors/txt.py:91 #: pacman_mirrors/txt.py:91
msgid "Use" msgid "Use"
...@@ -249,11 +247,11 @@ msgstr "Ülke" ...@@ -249,11 +247,11 @@ msgstr "Ülke"
#: pacman_mirrors/txt.py:93 #: pacman_mirrors/txt.py:93
msgid "Resp" msgid "Resp"
msgstr "Kısa" msgstr ""
#: pacman_mirrors/txt.py:94 #: pacman_mirrors/txt.py:94
msgid "Sync" msgid "Sync"
msgstr "Senk" msgstr ""
#: pacman_mirrors/txt.py:95 #: pacman_mirrors/txt.py:95
msgid "URL" msgid "URL"
......
...@@ -106,8 +106,10 @@ def build_config(): ...@@ -106,8 +106,10 @@ def build_config():
elif key == "SSL": elif key == "SSL":
config["ssl"] = value config["ssl"] = value
except (PermissionError, OSError) as err: except (PermissionError, OSError) as err:
print(".: {} {}: {}: {}".format(txt.ERR_CLR, txt.CANNOT_READ_FILE, print(".: {} {}: {}: {}".format(txt.ERR_CLR,
err.filename, err.strerror)) txt.CANNOT_READ_FILE,
err.filename,
err.strerror))
return config, custom return config, custom
...@@ -120,8 +122,10 @@ def modify_config(config, custom=False): ...@@ -120,8 +122,10 @@ def modify_config(config, custom=False):
# remove custom file if present # remove custom file if present
if os.path.isfile(config["custom_file"]): if os.path.isfile(config["custom_file"]):
os.remove(config["custom_file"]) os.remove(config["custom_file"])
write_configuration(config["config_file"], config["only_country"],
custom=custom) write_configuration(config["config_file"],
config["only_country"],
custom=custom)
def write_configuration(filename, selection, custom=False): def write_configuration(filename, selection, custom=False):
...@@ -140,8 +144,11 @@ def write_configuration(filename, selection, custom=False): ...@@ -140,8 +144,11 @@ def write_configuration(filename, selection, custom=False):
selection = "# OnlyCountry = \n" selection = "# OnlyCountry = \n"
try: try:
with open(filename) as cnf, tempfile.NamedTemporaryFile("w+t", with open(
dir=os.path.dirname(filename), delete=False) as tmp: filename) as cnf, tempfile.NamedTemporaryFile(
"w+t", dir=os.path.dirname(
filename), delete=False) as tmp:
replaced = False replaced = False
for line in cnf: for line in cnf:
if "OnlyCountry" in line: if "OnlyCountry" in line:
...@@ -155,5 +162,5 @@ def write_configuration(filename, selection, custom=False): ...@@ -155,5 +162,5 @@ def write_configuration(filename, selection, custom=False):
os.chmod(filename, 0o644) os.chmod(filename, 0o644)
except OSError as err: except OSError as err:
print(".: {} {}: {}: {}".format(txt.ERR_CLR, txt.CANNOT_READ_FILE, print(".: {} {}: {}: {}".format(txt.ERR_CLR, txt.CANNOT_READ_FILE,
err.filename, err.strerror)) err.filename, err.strerror))
exit(1) exit(1)
...@@ -25,6 +25,7 @@ import json ...@@ -25,6 +25,7 @@ import json
def list_to_tuple(list_data, named_tuple): def list_to_tuple(list_data, named_tuple):
""" """
Comvert list to a list with named tuples Comvert list to a list with named tuples
:param list_data: the list to convert :param list_data: the list to convert
:param named_tuple: tuple list item converts to :param named_tuple: tuple list item converts to
:return data: list of named tuples :return data: list of named tuples
...@@ -37,17 +38,20 @@ def list_to_tuple(list_data, named_tuple): ...@@ -37,17 +38,20 @@ def list_to_tuple(list_data, named_tuple):
def rows_from_tuple(servers, joiner=" | "): def rows_from_tuple(servers, joiner=" | "):
""" """
Generates equal formatted lines Generates equal formatted lines
:param servers: named tuples :param servers: named tuples
:param joiner: string used to join tuple items :param joiner: string used to join tuple items
:return lines: list of nicely formatted lines :return lines: list of nicely formatted lines
""" """
rows = [] rows = []
if servers: if not servers:
# calculate max col width return rows
col_width = [max(len(text) for text in col) for col in zip(*servers)]
# calculate max col width
# generate lines col_width = [max(len(text) for text in col) for col in zip(*servers)]
for line in servers:
rows.append(joiner.join("{:{}}".format(text, col_width[i]) # generate linies
for i, text in enumerate(line))) for line in servers:
rows.append(joiner.join("{:{}}".format(text, col_width[i])
for i, text in enumerate(line)))
return rows return rows
...@@ -81,6 +81,7 @@ class ConsoleUI(npyscreen.NPSAppManaged): ...@@ -81,6 +81,7 @@ class ConsoleUI(npyscreen.NPSAppManaged):
def done(self, selection): def done(self, selection):
""" """
After editing After editing
:param selection: :param selection:
""" """
if selection: if selection:
......
...@@ -27,6 +27,13 @@ from . import miscfn ...@@ -27,6 +27,13 @@ from . import miscfn
from . import txt from . import txt
def check_file(filename):
"""Check if file exist
:param filename:
"""
return os.path.isfile(filename)
def dir_must_exist(dir_name): def dir_must_exist(dir_name):
"""Check necessary directory """Check necessary directory
:param dir_name: :param dir_name:
...@@ -42,13 +49,13 @@ def return_mirror_filename(config): ...@@ -42,13 +49,13 @@ def return_mirror_filename(config):
filename = "" filename = ""
status = False # status.json or mirrors.json status = False # status.json or mirrors.json
# decision on file availablity # decision on file availablity
if os.path.isfile(config["status_file"]): if check_file(config["status_file"]):
status = True status = True
filename = config["status_file"] filename = config["status_file"]
elif os.path.isfile(config["mirror_file"]): elif check_file(config["mirror_file"]):
filename = config["mirror_file"] filename = config["mirror_file"]
elif os.path.isfile(config["fallback_file"]): elif check_file(config["fallback_file"]):
filename = config["fallback_file"] filename = config["fallback_file"]
if not filename: if not filename:
print("\n{}.:! {}{}\n".format(txt.RS, print("\n{}.:! {}{}\n".format(txt.RS,
txt.HOUSTON, txt.HOUSTON,
......
...@@ -87,8 +87,7 @@ class GraphicalUI(Gtk.Window): ...@@ -87,8 +87,7 @@ class GraphicalUI(Gtk.Window):
self.button_done = Gtk.Button(txt.I_CONFIRM, sensitive=False) self.button_done = Gtk.Button(txt.I_CONFIRM, sensitive=False)
self.button_done.connect("clicked", self.done) self.button_done.connect("clicked", self.done)
grid = Gtk.Grid(column_homogeneous=True, column_spacing=10, grid = Gtk.Grid(column_homogeneous=True, column_spacing=10, row_spacing=10)
row_spacing=10)
grid.attach(header, 0, 0, 2, 1) grid.attach(header, 0, 0, 2, 1)
grid.attach(scrolled_tree, 0, 1, 2, 1) grid.attach(scrolled_tree, 0, 1, 2, 1)
grid.attach(button_cancel, 0, 2, 1, 1) grid.attach(button_cancel, 0, 2, 1, 1)
...@@ -124,8 +123,8 @@ class GraphicalUI(Gtk.Window): ...@@ -124,8 +123,8 @@ class GraphicalUI(Gtk.Window):
def done(self, button): def done(self, button):
"""Confirm choice""" """Confirm choice"""
dialog = Gtk.Dialog(txt.I_CONFIRM_SELECTION, None, 0, ( dialog = Gtk.Dialog(txt.I_CONFIRM_SELECTION, None, 0, (
Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL, Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
Gtk.STOCK_OK, Gtk.ResponseType.OK)) Gtk.STOCK_OK, Gtk.ResponseType.OK))
dialog.set_transient_for(self) dialog.set_transient_for(self)
dialog.set_border_width(10) dialog.set_border_width(10)
box = dialog.get_content_area() box = dialog.get_content_area()
......
...@@ -61,7 +61,8 @@ def download_mirrors(config): ...@@ -61,7 +61,8 @@ def download_mirrors(config):
except (HTTPException, json.JSONDecodeError, URLError): except (HTTPException, json.JSONDecodeError, URLError):
pass pass
return (fetchmirrors, fetchstatus) result = (fetchmirrors, fetchstatus)
return result
def get_geoip_country(): def get_geoip_country():
...@@ -136,9 +137,11 @@ def is_connected(remote_host, maxwait=2): ...@@ -136,9 +137,11 @@ def is_connected(remote_host, maxwait=2):
# noinspection PyBroadException # noinspection PyBroadException
try: try:
data = urlopen(remote_host, timeout=maxwait) data = urlopen(remote_host, timeout=maxwait)
if data:
return True
except: except:
pass pass
return bool(data) return False
def ping_host(host, count=1): def ping_host(host, count=1):
...@@ -158,13 +161,12 @@ def update_mirrors(config): ...@@ -158,13 +161,12 @@ def update_mirrors(config):
:rtype: tuple :rtype: tuple
""" """
result = None result = None
connected = is_connected("http://repo.manjaro.org") mjro_online = is_connected("http://repo.manjaro.org")
if connected: if mjro_online:
print(".: {} {} {}".format(txt.INF_CLR, txt.DOWNLOADING_MIRROR_FILE, print(".: {} {} {}".format(txt.INF_CLR, txt.DOWNLOADING_MIRROR_FILE, txt.REPO_SERVER))
txt.REPO_SERVER))
result = download_mirrors(config) result = download_mirrors(config)
else: else:
if not os.path.isfile(config["mirror_file"]): if not filefn.check_file(config["mirror_file"]):
print(".: {} {} {} {}".format(txt.WRN_CLR, print(".: {} {} {} {}".format(txt.WRN_CLR,
txt.MIRROR_FILE, txt.MIRROR_FILE,
config["mirror_file"], config["mirror_file"],
...@@ -173,7 +175,8 @@ def update_mirrors(config): ...@@ -173,7 +175,8 @@ def update_mirrors(config):
txt.FALLING_BACK, txt.FALLING_BACK,
conf.FALLBACK)) conf.FALLBACK))
result = (True, False) result = (True, False)
if not os.path.isfile(config["fallback_file"]): if not filefn.check_file(config["fallback_file"]):
print(".: {} {}".format(txt.ERR_CLR, txt.HOUSTON)) print(".: {} {}".format(txt.ERR_CLR, txt.HOUSTON))
result = (False, False) result = (False, False)
return result return result
...@@ -34,6 +34,7 @@ def read_json_file(filename, dictionary=True): ...@@ -34,6 +34,7 @@ def read_json_file(filename, dictionary=True):
else: else:
with open(filename, "r") as infile: with open(filename, "r") as infile:
result = json.load(infile) result = json.load(infile)
except OSError: except OSError:
pass pass
return result return result
......
...@@ -67,6 +67,6 @@ class Mirror: ...@@ -67,6 +67,6 @@ class Mirror:
for server in mirrors: for server in mirrors:
if status: if status:
self.add(server["country"], server["url"], server["protocols"], self.add(server["country"], server["url"], server["protocols"],
server["branches"], server["last_sync"]) server["branches"], server["last_sync"])
else: else:
self.add(server["country"], server["url"], server["protocols"]) self.add(server["country"], server["url"], server["protocols"])
...@@ -32,14 +32,19 @@ def build_country_list(selectedcountries, countrylist, geoip=False): ...@@ -32,14 +32,19 @@ def build_country_list(selectedcountries, countrylist, geoip=False):
:rtype: list :rtype: list
""" """
result = [] result = []
if selectedcountries == ["all"]: if selectedcountries:
result = countrylist if selectedcountries == ["all"]:
elif validfn.country_list_is_valid(selectedcountries, countrylist): result = countrylist
result = selectedcountries else:
if not result and geoip: if validfn.country_list_is_valid(selectedcountries, countrylist):
country = get_geoip_country(countrylist) result = selectedcountries
if country: # valid geoip if not result:
result = country if geoip:
country = get_geoip_country(countrylist)
if country: # valid geoip
result = country
else:
result = countrylist
else: else:
result = countrylist result = countrylist
return result return result
......
...@@ -44,4 +44,5 @@ def terminal_size(): ...@@ -44,4 +44,5 @@ def terminal_size():
# http://www.programcreek.com/python/example/85471/shutil.get_terminal_size # http://www.programcreek.com/python/example/85471/shutil.get_terminal_size
cols = shutil.get_terminal_size().columns cols = shutil.get_terminal_size().columns
lines = shutil.get_terminal_size().lines lines = shutil.get_terminal_size().lines
return (cols, lines) result = (cols, lines)
return result
...@@ -123,8 +123,7 @@ class PacmanMirrors: ...@@ -123,8 +123,7 @@ class PacmanMirrors:
parser.add_argument("-f", "--fasttrack", parser.add_argument("-f", "--fasttrack",
type=int, type=int,
metavar=txt.DIGIT, metavar=txt.DIGIT,
help="{} {}".format(txt.HLP_ARG_FASTTRACK, help="{} {}".format(txt.HLP_ARG_FASTTRACK, txt.OVERRIDE_OPT))
txt.OVERRIDE_OPT))
parser.add_argument("-l", "--list", parser.add_argument("-l", "--list",
action="store_true", action="store_true",
help=txt.HLP_ARG_LIST) help=txt.HLP_ARG_LIST)
...@@ -350,8 +349,7 @@ class PacmanMirrors: ...@@ -350,8 +349,7 @@ class PacmanMirrors:
if self.default and custom_list: if self.default and custom_list:
if self.config["method"] == "rank": if self.config["method"] == "rank":
custom_list = self.test_mirrors(custom_list) custom_list = self.test_mirrors(custom_list)
custom_list = sorted(custom_list, custom_list = sorted(custom_list, key=itemgetter("resp_time"))
key=itemgetter("resp_time"))
else: else:
shuffle(custom_list) shuffle(custom_list)
...@@ -372,18 +370,13 @@ class PacmanMirrors: ...@@ -372,18 +370,13 @@ class PacmanMirrors:
print("--------------------------") print("--------------------------")
# output mirror file # output mirror file
jsonfn.write_json_file(mirrorfile, self.config["custom_file"]) jsonfn.write_json_file(mirrorfile, self.config["custom_file"])
print(".: {} {}: {}".format(txt.INF_CLR, print(".: {} {}: {}".format(txt.INF_CLR, txt.CUSTOM_MIRROR_FILE_SAVED, self.config["custom_file"]))
txt.CUSTOM_MIRROR_FILE_SAVED,
self.config["custom_file"]))
# output pacman mirrorlist # output pacman mirrorlist
filefn.output_mirror_list(self.config, selected, filefn.output_mirror_list(self.config, selected, custom=True, quiet=self.quiet, interactive=True)
custom=True, quiet=self.quiet,
interactive=True)
# always use "Custom" from interactive # always use "Custom" from interactive
self.config["only_country"] = ["Custom"] self.config["only_country"] = ["Custom"]
configfn.modify_config(self.config, custom=True) configfn.modify_config(self.config, custom=True)
print(".: {} {} {}".format(txt.INF_CLR, txt.RESET_CUSTOM_CONFIG, print(".: {} {} {}".format(txt.INF_CLR, txt.RESET_CUSTOM_CONFIG, txt.RESET_TIP))
txt.RESET_TIP))
else: else:
print(".: {} {}".format(txt.WRN_CLR, txt.NO_SELECTION)) print(".: {} {}".format(txt.WRN_CLR, txt.NO_SELECTION))
print(".: {} {}".format(txt.INF_CLR, txt.NO_CHANGE)) print(".: {} {}".format(txt.INF_CLR, txt.NO_CHANGE))
......
[{"country":"Australia","url":"http://mirror.ventraip.net.au/Manjaro/","protocols":["http"]},{"country":"Australia","url":"http://manjaro.uberglobalmirror.com/","protocols":["http"]},{"country":"Australia","url":"http://manjaro.mirror.serversaustralia.com.au/","protocols":["http"]},{"country":"Austria","url":"http://mirror.inode.at/manjaro/","protocols":["http"]},{"country":"Belarus","url":"http://mirror.datacenter.by/pub/mirrors/manjaro/","protocols":["http"]},{"country":"Belgium","url":"http://ftp.belnet.be/manjaro/","protocols":["ftp","http"]},{"country":"Belgium","url":"https://manjaro.cu.be/","protocols":["https"]},{"country":"Brasil","url":"http://linorg.usp.br/manjaro/","protocols":["http"]},{"country":"Bulgaria","url":"https://mirrors.netix.net/manjaro/","protocols":["http","https"]},{"country":"Bulgaria","url":"http://manjaro.ipacct.com/manjaro/","protocols":["http"]},{"country":"Bulgaria","url":"http://manjaro.telecoms.bg/","protocols":["http"]},{"country":"Canada","url":"http://manjaro.cybr.ca/","protocols":["http"]},{"country":"Canada","url":"https://ca.mirror.babylon.network/manjaro/","protocols":["https"]},{"country":"Chile","url":"http://manjaro.dcc.uchile.cl/","protocols":["http"]},{"country":"Chile","url":"http://doge.ing.puc.cl/Mirrors/Manjaro/","protocols":["http"]},{"country":"China","url":"http://mirrors.ustc.edu.cn/manjaro/","protocols":["http"]},{"country":"China","url":"http://ftp.cuhk.edu.hk/pub/Linux/manjaro/","protocols":["ftp","http"]},{"country":"China","url":"http://mirrors.tuna.tsinghua.edu.cn/manjaro/","protocols":["http"]},{"country":"China","url":"https://mirrors.zju.edu.cn/manjaro/","protocols":["http","https"]},{"country":"Colombia","url":"http://mirror.edatel.net.co/manjaro/","protocols":["http"]},{"country":"Costa_Rica","url":"http://mirrors.ucr.ac.cr/manjaro/","protocols":["http"]},{"country":"Czech","url":"https://mirror.dkm.cz/manjaro/","protocols":["http","https"]},{"country":"Denmark","url":"https://mirrors.dotsrc.org/manjaro/","protocols":["http","https"]},{"country":"Denmark","url":"https://www.uex.dk/repos/manjaro/","protocols":["http","https"]},{"country":"Ecuador","url":"https://mirror.cedia.org.ec/manjaro/","protocols":["http","https"]},{"country":"Ecuador","url":"https://mirror.uta.edu.ec/manjaro/","protocols":["http","https"]},{"country":"Ecuador","url":"https://mirror.espoch.edu.ec/manjaro/","protocols":["http","https"]},{"country":"France","url":"http://manjarolinux.polymorf.fr/","protocols":["http"]},{"country":"France","url":"http://mirror.lignux.com/manjaro/","protocols":["http"]},{"country":"France","url":"http://ftp.free.org/mirrors/repo.manjaro.org/repos/","protocols":["ftp","http"]},{"country":"France","url":"https://fr.mirror.babylon.network/manjaro/","protocols":["https"]},{"country":"Germany","url":"http://mirror.ragenetwork.de/manjaro/","protocols":["http"]},{"country":"Germany","url":"http://ftp.halifax.rwth-aachen.de/manjaro/","protocols":["ftp","http"]},{"country":"Germany","url":"http://ftp.tu-chemnitz.de/pub/linux/manjaro/","protocols":["ftp","http"]},{"country":"Germany","url":"https://mirror.netzspielplatz.de/manjaro/packages/","protocols":["https"]},{"country":"Germany","url":"https://mirror.netcologne.de/manjaro/","protocols":["https"]},{"country":"Germany","url":"https://repo.rhindon.net/manjaro/","protocols":["https"]},{"country":"Germany","url":"https://repo.stdout.net/manjaro/","protocols":["http","https"]},{"country":"Germany","url":"https://manjaro-mirror-a.alpix.eu/","protocols":["http","https"]},{"country":"Germany","url":"http://ftp.rz.tu-bs.de/pub/mirror/manjaro.org/repos/","protocols":["ftp","http"]},{"country":"Greece","url":"http://ftp.cc.uoc.gr/mirrors/linux/manjaro/","protocols":["ftp","http"]},{"country":"Hungary","url":"http://mirror.infotronik.hu/mirrors/pub/manjaro/","protocols":["http"]},{"country":"Indonesia","url":"http://kambing.ui.ac.id/manjaro/","protocols":["http"]},{"country":"Indonesia","url":"http://kartolo.sby.datautama.net.id/manjaro/","protocols":["http"]},{"country":"Indonesia","url":"http://jaran.undip.ac.id/manjaro/","protocols":["http"]},{"country":"Ireland","url":"https://ftp.heanet.ie/mirrors/manjaro/","protocols":["ftp","https"]},{"country":"Italy","url":"http://manjaro.mirror.garr.it/mirrors/manjaro/","protocols":["http"]},{"country":"Italy","url":"http://ba.mirror.garr.it/mirrors/manjaro/","protocols":["http"]},{"country":"Italy","url":"http://ct.mirror.garr.it/mirrors/manjaro/","protocols":["http"]},{"country":"Japan","url":"http://ftp.tsukuba.wide.ad.jp/Linux/manjaro/","protocols":["ftp","http"]},{"country":"Japan","url":"http://ftp.riken.jp/Linux/manjaro/","protocols":["ftp","http"]},{"country":"Netherlands","url":"http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/","protocols":["ftp","http"]},{"country":"Netherlands","url":"http://ftp.snt.utwente.nl/pub/linux/manjaro/","protocols":["ftp","http"]},{"country":"Netherlands","url":"https://nl.mirror.babylon.network/manjaro/","protocols":["https"]},{"country":"Philippines","url":"http://mirror.rise.ph/manjaro/","protocols":["http"]},{"country":"Poland","url":"http://mirror.chmuri.net/manjaro/","protocols":["http"]},{"country":"Portugal","url":"http://ftp.dei.uc.pt/pub/linux/manjaro/","protocols":["ftp","http"]},{"country":"Portugal","url":"http://manjaro.barata.pt/","protocols":["http"]},{"country":"Romania","url":"http://mirrors.serverhost.ro/manjaro/packages/","protocols":["http"]},{"country":"Romania","url":"http://ftp.lug.ro/manjaro/","protocols":["ftp","http"]},{"country":"Russia","url":"https://mirror.yandex.ru/mirrors/manjaro/","protocols":["http","https"]},{"country":"Singapore","url":"http://download.nus.edu.sg/mirror/manjaro/","protocols":["http"]},{"country":"South_Africa","url":"http://mirror.is.co.za/mirrors/manjaro.org/","protocols":["http"]},{"country":"Sweden","url":"https://ftp.lysator.liu.se/pub/manjaro/","protocols":["ftp","https"]},{"country":"Sweden","url":"http://mirror.zetup.net/manjaro/","protocols":["http"]},{"country":"Taiwan","url":"http://free.nchc.org.tw/manjaro/","protocols":["http"]},{"country":"Turkey","url":"http://ftp.linux.org.tr/manjaro/","protocols":["ftp","http"]},{"country":"United_Kingdom","url":"http://repo.manjaro.org.uk/","protocols":["http"]},{"country":"United_Kingdom","url":"https://www.mirrorservice.org/sites/repo.manjaro.org/repos/","protocols":["https"]},{"country":"United_Kingdom","url":"http://mirror.catn.com/pub/manjaro/","protocols":["http"]},{"country":"United_Kingdom","url":"http://manjaro.mirrors.uk2.net/","protocols":["http"]},{"country":"United_States","url":"http://mirror.dacentec.com/manjaro/","protocols":["http"]},{"country":"United_States","url":"http://mirror.jmu.edu/manjaro/","protocols":["http"]},{"country":"United_States","url":"http://mirror.solarvps.com/manjaro/","protocols":["http"]},{"country":"United_States","url":"http://mirror.nexcess.net/manjaro/","protocols":["http"]},{"country":"United_States","url":"http://distro.ibiblio.org/manjaro/","protocols":["http"]},{"country":"United_States","url":"http://mirror.clarkson.edu/manjaro/","protocols":["http"]},{"country":"United_States","url":"http://mirrors.ocf.berkeley.edu/manjaro/","protocols":["http"]},{"country":"Vietnam","url":"https://mirror.freedif.org/Manjaro/","protocols":["https"]}] [{"country": "Australia", "url": "http://mirror.ventraip.net.au/Manjaro/", "protocols": ["http"]}, {"country": "Australia", "url": "http://manjaro.uberglobalmirror.com/", "protocols": ["http"]}, {"country": "Australia", "url": "http://manjaro.mirror.serversaustralia.com.au/", "protocols": ["http"]}, {"country": "Austria", "url": "http://mirror.inode.at/manjaro/", "protocols": ["http"]}, {"country": "Belarus", "url": "http://mirror.datacenter.by/pub/mirrors/manjaro/", "protocols": ["http"]}, {"country": "Belgium", "url": "http://ftp.belnet.be/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Belgium", "url": "https://manjaro.cu.be/", "protocols": ["https"]}, {"country": "Brasil", "url": "http://linorg.usp.br/manjaro/", "protocols": ["http"]}, {"country": "Bulgaria", "url": "https://mirrors.netix.net/manjaro/", "protocols": ["http", "https"]}, {"country": "Bulgaria", "url": "http://manjaro.ipacct.com/manjaro/", "protocols": ["http"]}, {"country": "Bulgaria", "url": "http://manjaro.telecoms.bg/", "protocols": ["http"]}, {"country": "Canada", "url": "http://manjaro.cybr.ca/", "protocols": ["http"]}, {"country": "Canada", "url": "https://ca.mirror.babylon.network/manjaro/", "protocols": ["https"]}, {"country": "Chile", "url": "http://manjaro.dcc.uchile.cl/", "protocols": ["http"]}, {"country": "Chile", "url": "http://doge.ing.puc.cl/Mirrors/Manjaro/", "protocols": ["http"]}, {"country": "China", "url": "http://mirrors.ustc.edu.cn/manjaro/", "protocols": ["http"]}, {"country": "China", "url": "http://ftp.cuhk.edu.hk/pub/Linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "China", "url": "http://mirrors.tuna.tsinghua.edu.cn/manjaro/", "protocols": ["http"]}, {"country": "China", "url": "https://mirrors.zju.edu.cn/manjaro/", "protocols": ["http", "https"]}, {"country": "Colombia", "url": "http://mirror.edatel.net.co/manjaro/", "protocols": ["http"]}, {"country": "Costa_Rica", "url": "http://mirrors.ucr.ac.cr/manjaro/", "protocols": ["http"]}, {"country": "Czech", "url": "https://mirror.dkm.cz/manjaro/", "protocols": ["http", "https"]}, {"country": "Denmark", "url": "https://mirrors.dotsrc.org/manjaro/", "protocols": ["http", "https"]}, {"country": "Denmark", "url": "http://www.uex.dk/repos/manjaro/", "protocols": ["http"]}, {"country": "Ecuador", "url": "https://mirror.cedia.org.ec/manjaro/", "protocols": ["http", "https"]}, {"country": "Ecuador", "url": "https://mirror.uta.edu.ec/manjaro/", "protocols": ["http", "https"]}, {"country": "Ecuador", "url": "https://mirror.espoch.edu.ec/manjaro/", "protocols": ["http", "https"]}, {"country": "France", "url": "http://manjarolinux.polymorf.fr/", "protocols": ["http"]}, {"country": "France", "url": "http://mirror.lignux.com/manjaro/", "protocols": ["http"]}, {"country": "France", "url": "http://ftp.free.org/mirrors/repo.manjaro.org/repos/", "protocols": ["ftp", "http"]}, {"country": "France", "url": "https://fr.mirror.babylon.network/manjaro/", "protocols": ["https"]}, {"country": "Germany", "url": "http://mirror.ragenetwork.de/manjaro/", "protocols": ["http"]}, {"country": "Germany", "url": "http://ftp.halifax.rwth-aachen.de/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Germany", "url": "http://ftp.tu-chemnitz.de/pub/linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Germany", "url": "https://mirror.netzspielplatz.de/manjaro/packages/", "protocols": ["https"]}, {"country": "Germany", "url": "https://mirror.netcologne.de/manjaro/", "protocols": ["https"]}, {"country": "Germany", "url": "https://repo.rhindon.net/manjaro/", "protocols": ["https"]}, {"country": "Germany", "url": "http://mirrors.cicku.me/manjaro/", "protocols": ["http"]}, {"country": "Germany", "url": "https://repo.stdout.net/manjaro/", "protocols": ["http", "https"]}, {"country": "Germany", "url": "https://manjaro-mirror-a.alpix.eu/", "protocols": ["http", "https"]}, {"country": "Germany", "url": "http://ftp.rz.tu-bs.de/pub/mirror/manjaro.org/repos/", "protocols": ["ftp", "http"]}, {"country": "Greece", "url": "http://ftp.cc.uoc.gr/mirrors/linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Hungary", "url": "http://mirror.infotronik.hu/mirrors/pub/manjaro/", "protocols": ["http"]}, {"country": "Indonesia", "url": "http://kambing.ui.ac.id/manjaro/", "protocols": ["http"]}, {"country": "Indonesia", "url": "http://kartolo.sby.datautama.net.id/manjaro/", "protocols": ["http"]}, {"country": "Indonesia", "url": "http://jaran.undip.ac.id/manjaro/", "protocols": ["http"]}, {"country": "Ireland", "url": "https://ftp.heanet.ie/mirrors/manjaro/", "protocols": ["ftp", "https"]}, {"country": "Italy", "url": "http://manjaro.mirror.garr.it/mirrors/manjaro/", "protocols": ["http"]}, {"country": "Italy", "url": "http://ba.mirror.garr.it/mirrors/manjaro/", "protocols": ["http"]}, {"country": "Italy", "url": "http://ct.mirror.garr.it/mirrors/manjaro/", "protocols": ["http"]}, {"country": "Japan", "url": "http://ftp.tsukuba.wide.ad.jp/Linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Japan", "url": "http://ftp.riken.jp/Linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Netherlands", "url": "http://ftp.nluug.nl/pub/os/Linux/distr/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Netherlands", "url": "http://ftp.snt.utwente.nl/pub/linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Netherlands", "url": "https://nl.mirror.babylon.network/manjaro/", "protocols": ["https"]}, {"country": "Philippines", "url": "http://mirror.rise.ph/manjaro/", "protocols": ["http"]}, {"country": "Poland", "url": "http://mirror.chmuri.net/manjaro/", "protocols": ["http"]}, {"country": "Portugal", "url": "http://ftp.dei.uc.pt/pub/linux/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Portugal", "url": "http://repo.barata.website/", "protocols": ["http"]}, {"country": "Romania", "url": "http://mirrors.serverhost.ro/manjaro/packages/", "protocols": ["http"]}, {"country": "Romania", "url": "http://ftp.lug.ro/manjaro/", "protocols": ["ftp", "http"]}, {"country": "Russia", "url": "https://mirror.yandex.ru/mirrors/manjaro/", "protocols": ["http", "https"]}, {"country": "Russia", "url": "ftp://kibo.remi.lu/pub/", "protocols": ["ftp"]}, {"country": "Singapore", "url": "http://download.nus.edu.sg/mirror/manjaro/", "protocols": ["http"]}, {"country": "South_Africa", "url": "http://mirror.is.co.za/mirrors/manjaro.org/", "protocols": ["http"]}, {"country": "Sweden", "url": "https://ftp.lysator.liu.se/pub/manjaro/", "protocols": ["ftp", "https"]}, {"country": "Sweden", "url": "http://mirror.zetup.net/manjaro/", "protocols": ["http"]}, {"country": "Taiwan", "url": "http://free.nchc.org.tw/manjaro/", "protocols": ["http"]}, {"country": "Turkey", "url": "http://ftp.linux.org.tr/manjaro/", "protocols": ["ftp", "http"]}, {"country": "United_Kingdom", "url": "http://repo.manjaro.org.uk/", "protocols": ["http"]}, {"country": "United_Kingdom", "url": "https://www.mirrorservice.org/sites/repo.manjaro.org/repos/", "protocols": ["https"]}, {"country": "United_Kingdom", "url": "http://mirror.catn.com/pub/manjaro/", "protocols": ["http"]}, {"country": "United_Kingdom", "url": "http://manjaro.mirrors.uk2.net/", "protocols": ["http"]}, {"country": "United_States", "url": "http://mirror.dacentec.com/manjaro/", "protocols": ["http"]}, {"country": "United_States", "url": "http://mirror.jmu.edu/manjaro/", "protocols": ["http"]}, {"country": "United_States", "url": "http://mirror.solarvps.com/manjaro/", "protocols": ["http"]}, {"country": "United_States", "url": "http://mirror.nexcess.net/manjaro/", "protocols": ["http"]}, {"country": "United_States", "url": "http://distro.ibiblio.org/manjaro/", "protocols": ["http"]}, {"country": "United_States", "url": "http://mirror.clarkson.edu/manjaro/", "protocols": ["http"]}, {"country": "United_States", "url": "http://mirrors.ocf.berkeley.edu/manjaro/", "protocols": ["http"]}, {"country": "Vietnam", "url": "https://mirror.freedif.org/Manjaro/", "protocols": ["https"]}]
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment