Skip to content

Instantly share code, notes, and snippets.

@navossoc
Created August 25, 2018 02:39
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save navossoc/0aa9afe23c3815ede003414198722e34 to your computer and use it in GitHub Desktop.
Save navossoc/0aa9afe23c3815ede003414198722e34 to your computer and use it in GitHub Desktop.
#!/bin/bash
# mirror list
#wget -qO - mirrors.ubuntu.com/mirrors.txt
# replace apt-get mirror's with a country mirror
sed -i -E 's/deb(-src)? http:\/\/.+\/\b/deb\1 http:\/\/br.archive.ubuntu.com\//' /etc/apt/sources.list
# mirror protocol
# sed -E 's/deb(-src)? http:\/\/.+ /deb\1 mirror:\/\/mirrors.ubuntu.com\/mirrors.txt /' /etc/apt/sources.list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment