Difference between revisions of "Pacman-mirrors"

add template UserCmd
(Using -yy is bad practice)
(add template UserCmd)
Line 26: Line 26:


  <!--T:8-->
  <!--T:8-->
$ sudo pacman-mirrors
{{UserCmd|command=sudo pacman-mirrors}}


<!--T:9-->
<!--T:9-->
Line 35: Line 35:


  <!--T:11-->
  <!--T:11-->
$ sudo pacman -Syu
{{UserCmd|command=sudo pacman -Syu}}


<!--T:12-->
<!--T:12-->
Line 50: Line 50:


====Man page==== <!--T:15-->
====Man page==== <!--T:15-->
man pacman-mirrors
{{UserCmd|command=man pacman-mirrors}}


====Help on usage==== <!--T:16-->
====Help on usage==== <!--T:16-->
pacman-mirrors --help
{{UserCmd|command=pacman-mirrors --help}}


====Version==== <!--T:17-->
====Version==== <!--T:17-->
pacman-mirrors --version
{{UserCmd|command=pacman-mirrors --version}}


====Mirror status==== <!--T:18-->
====Mirror status==== <!--T:18-->
pacman-mirrors --status
{{UserCmd|command=pacman-mirrors --status}}


====List available countries==== <!--T:19-->
====List available countries==== <!--T:19-->
In default mirror pool
In default mirror pool
pacman-mirrors --country-list
{{UserCmd|command=pacman-mirrors --country-list}}


<!--T:20-->
<!--T:20-->
In custom mirror pool
In custom mirror pool
pacman-mirrors --country-config
{{UserCmd|command=pacman-mirrors --country-config}}


====What branch am I on==== <!--T:21-->
====What branch am I on==== <!--T:21-->
pacman-mirrors --get-branch
{{UserCmd|command=pacman-mirrors --get-branch}}


===Commands using defaults=== <!--T:22-->
===Commands using defaults=== <!--T:22-->


====Update mirrorlist with the fastest mirrors==== <!--T:23-->
====Update mirrorlist with the fastest mirrors==== <!--T:23-->
sudo pacman-mirrors --fasttrack && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --fasttrack && sudo pacman -Syu}}


====Limit to 5 mirrors==== <!--T:24-->
====Limit to 5 mirrors==== <!--T:24-->
An optional number can be supplied to limit the number of mirrors in the mirrorlist
An optional number can be supplied to limit the number of mirrors in the mirrorlist
sudo pacman-mirrors --fasttrack 5 && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --fasttrack 5 && sudo pacman -Syu}}


====Mirrors for your country only==== <!--T:25-->
====Mirrors for your country only==== <!--T:25-->
Not all countries have mirrors, if geoip returns a country not in the pool all mirrors will be used.
Not all countries have mirrors, if geoip returns a country not in the pool all mirrors will be used.
sudo pacman-mirrors --geoip && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --geoip && sudo pacman -Syu}}


===Commands customizing the mirror pool=== <!--T:26-->
===Commands customizing the mirror pool=== <!--T:26-->
Line 93: Line 93:
====Customize mirror pool by continent==== <!--T:28-->
====Customize mirror pool by continent==== <!--T:28-->
Create a custom mirror pool using mirrors from the continent determined by querying a geolocation service
Create a custom mirror pool using mirrors from the continent determined by querying a geolocation service
sudo pacman-mirrors --continent && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --continent && sudo pacman -Syu}}


====Customize mirror pool by countries==== <!--T:29-->
====Customize mirror pool by countries==== <!--T:29-->
Create a custom mirror pool using mirrors from Germany, France and Austria
Create a custom mirror pool using mirrors from Germany, France and Austria
sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu}}


====Customize mirror pool by interactive selection==== <!--T:30-->
====Customize mirror pool by interactive selection==== <!--T:30-->
Create a custom mirror pool using the '''--default''' mirror pool '''--interactive''' will list all available mirrors and procotols in a gui windows allowing to sort the columns and interactively select according to your preferences.
Create a custom mirror pool using the '''--default''' mirror pool '''--interactive''' will list all available mirrors and procotols in a gui windows allowing to sort the columns and interactively select according to your preferences.
sudo pacman-mirrors --interactive --default && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --interactive --default && sudo pacman -Syu}}


====Use specific protocols (prioritized)==== <!--T:31-->
====Use specific protocols (prioritized)==== <!--T:31-->
Rank the current mirror pool using only https and http protocol
Rank the current mirror pool using only https and http protocol
sudo pacman-mirrors --api --protocol https,http && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --api --protocol https,http && sudo pacman -Syu}}


====Switch branch to unstable and use German mirrors==== <!--T:32-->
====Switch branch to unstable and use German mirrors==== <!--T:32-->
Change the system branch to unstable and create a custom mirror pool using mirrors from Germany
Change the system branch to unstable and create a custom mirror pool using mirrors from Germany
sudo pacman-mirrors --country Germany --api --set-branch unstable && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Germany --api --set-branch unstable && sudo pacman -Syu}}


==== Switch branch and use German mirrors with https==== <!--T:33-->
==== Switch branch and use German mirrors with https==== <!--T:33-->
Change the system branch to unstable, set configuration to use https only and create a custom mirror pool using mirrors from Germany
Change the system branch to unstable, set configuration to use https only and create a custom mirror pool using mirrors from Germany
sudo pacman-mirrors --country Germany --api --set-branch unstable --protocol https && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Germany --api --set-branch unstable --protocol https && sudo pacman -Syu}}


===Reset=== <!--T:34-->
===Reset=== <!--T:34-->
Line 119: Line 119:


  <!--T:35-->
  <!--T:35-->
sudo pacman-mirrors --country all --api --protocols all --set-branch stable && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country all --api --protocols all --set-branch stable && sudo pacman -Syu}}


==Overview== <!--T:36-->
==Overview== <!--T:36-->
Line 1,987: Line 1,987:


  <!--T:73-->
  <!--T:73-->
$ sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu}}


<!--T:74-->
<!--T:74-->
Line 1,993: Line 1,993:


  <!--T:75-->
  <!--T:75-->
$ sudo pacman-mirrors --country Antarctica && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Antarctica && sudo pacman -Syu}}
  .: Info Downloading mirrors from repo.manjaro.org
  .: Info Downloading mirrors from repo.manjaro.org
  .: Warning Option '-c/--country' : unknown country: 'Antarctica'
  .: Warning Option '-c/--country' : unknown country: 'Antarctica'
Line 2,024: Line 2,024:
<!--T:80-->
<!--T:80-->
'''First option''' is using ''--interactive''. It uses your current mirror pool(whether default or custom)
'''First option''' is using ''--interactive''. It uses your current mirror pool(whether default or custom)
$ sudo pacman-mirrors --interactive && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --interactive && sudo pacman -Syu}}


<!--T:81-->
<!--T:81-->
'''Second option''' is using ''--interactive --default''. This force the use of the official mirror pool
'''Second option''' is using ''--interactive --default''. This force the use of the official mirror pool
$ sudo pacman-mirrors --interactive --default && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --interactive --default && sudo pacman -Syu}}


<!--T:82-->
<!--T:82-->
'''Third option''' is supplying a list of countries with ''--country''. The countries is an example - check the country list if in doubt.
'''Third option''' is supplying a list of countries with ''--country''. The countries is an example - check the country list if in doubt.
$ sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu}}


<!--T:83-->
<!--T:83-->
'''Fourth option''' is ''--continent''. The countries used is determined by the continent they are assigned to and can optionally be combined with '''--interactive'''.
'''Fourth option''' is ''--continent''. The countries used is determined by the continent they are assigned to and can optionally be combined with '''--interactive'''.
$ sudo pacman-mirrors --continent [--interactive]
{{UserCmd|command=sudo pacman-mirrors --continent [--interactive]}}


<!--T:84-->
<!--T:84-->
Line 2,051: Line 2,051:


  <!--T:88-->
  <!--T:88-->
$ sudo pacman-mirrors --country all && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country all && sudo pacman -Syu}}


<!--T:89-->
<!--T:89-->
Line 2,057: Line 2,057:


  <!--T:90-->
  <!--T:90-->
$ sudo pacman-mirrors --interactive --default && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --interactive --default && sudo pacman -Syu}}
* You will be presented with a list with all and every mirror and you can pick your selection.
* You will be presented with a list with all and every mirror and you can pick your selection.


Line 2,063: Line 2,063:
'''Third option''' is to supply a list of countries and use those for a custom mirror pool.
'''Third option''' is to supply a list of countries and use those for a custom mirror pool.
The countries is an example - check the country list if in doubt.
The countries is an example - check the country list if in doubt.
  $ sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country Germany,France,Austria && sudo pacman -Syu}}
* If you supply the same preferred countries on every reset you will get your mirror pool updated with added or removed mirrors.
* If you supply the same preferred countries on every reset you will get your mirror pool updated with added or removed mirrors.


Line 2,070: Line 2,070:


=== Apply pacman-mirrors defaults === <!--T:93-->
=== Apply pacman-mirrors defaults === <!--T:93-->
sudo pacman-mirrors --country all --api --protocol all -set-branch stable && sudo pacman -Syu
{{UserCmd|command=sudo pacman-mirrors --country all --api --protocol all -set-branch stable && sudo pacman -Syu}}


<!--T:94-->
<!--T:94-->
translator
11,127

edits