aquaballoon

sh - if

Nov 30th, 2011
167
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 3.53 KB | None | 0 0
  1. #! /bin/bash
  2.  
  3. #cp /etc/apt/sources.list  /etc/apt/sources.list.org
  4.  
  5. echo "Enter 1 for Ubuntu 9.04; 2 for Ubuntu 10.04; 3 for Ubuntu 11.10"
  6.  
  7. read Ubuntu
  8.  
  9. if [ $Ubuntu = 1 ]; then
  10. echo "## Ubuntu 9.04 ONLY!!
  11.  
  12. deb http://old-releases.ubuntu.com/ubuntu/ jaunty main restricted
  13. deb-src http://old-releases.ubuntu.com/ubuntu/ jaunty main restricted
  14. deb http://old-releases.ubuntu.com/ubuntu/ jaunty-updates main restricted
  15. deb-src http://old-releases.ubuntu.com/ubuntu/ jaunty-updates main restricted
  16. deb http://old-releases.ubuntu.com/ubuntu/ jaunty universe
  17. deb-src http://old-releases.ubuntu.com/ubuntu/ jaunty universe
  18. deb http://old-releases.ubuntu.com/ubuntu/ jaunty-updates universe
  19. deb-src http://old-releases.ubuntu.com/ubuntu/ jaunty-updates universe
  20. deb http://old-releases.ubuntu.com/ubuntu/ jaunty multiverse
  21. deb-src http://old-releases.ubuntu.com/ubuntu/ jaunty multiverse
  22. deb http://old-releases.ubuntu.com/ubuntu/ jaunty-updates multiverse
  23. deb-src http://old-releases.ubuntu.com/ubuntu/ jaunty-updates multiverse
  24. deb http://old-releases.ubuntu.com/ubuntu/ jaunty-backports main restricted universe multiverse
  25. deb http://old-releases.ubuntu.com/ubuntu jaunty-security main restricted
  26. deb-src http://old-releases.ubuntu.com/ubuntu jaunty-security main restricted
  27. deb http://old-releases.ubuntu.com/ubuntu jaunty-security universe
  28. deb-src http://old-releases.ubuntu.com/ubuntu jaunty-security universe
  29. deb http://old-releases.ubuntu.com/ubuntu jaunty-security multiverse
  30. deb http://old-releases.ubuntu.com/ubuntu/ jaunty-proposed restricted main multiverse universe
  31. deb-src http://old-releases.ubuntu.com/ubuntu jaunty-security multiverse " > /etc/apt/sources.list
  32.  
  33. nano /etc/apt/sources.list
  34.  
  35. elif [ $Ubuntu = 2 ]; then
  36.  
  37. echo "Ubuntu 10.04 is not available now!"
  38.  
  39. elif [ $Ubuntu = 3 ]; then
  40. echo "## Ubuntu 11.10 ONLY!!
  41.  
  42. deb http://archive.ubuntu.com/ubuntu oneiric main restricted
  43. deb-src http://archive.ubuntu.com/ubuntu oneiric main restricted
  44. deb http://archive.ubuntu.com/ubuntu oneiric-updates main restricted
  45. deb-src http://archive.ubuntu.com/ubuntu oneiric-updates main restricted
  46. deb http://archive.ubuntu.com/ubuntu oneiric universe
  47. deb-src http://archive.ubuntu.com/ubuntu oneiric universe
  48. deb http://archive.ubuntu.com/ubuntu oneiric-updates universe
  49. deb-src http://archive.ubuntu.com/ubuntu oneiric-updates universe
  50. deb http://archive.ubuntu.com/ubuntu oneiric multiverse
  51. deb-src http://archive.ubuntu.com/ubuntu oneiric multiverse
  52. deb http://archive.ubuntu.com/ubuntu oneiric-updates multiverse
  53. deb-src http://archive.ubuntu.com/ubuntu oneiric-updates multiverse
  54. deb http://archive.ubuntu.com/ubuntu oneiric-backports main restricted universe multiverse
  55. deb-src http://archive.ubuntu.com/ubuntu oneiric-backports main restricted universe multiverse
  56. deb http://archive.ubuntu.com/ubuntu oneiric-security main restricted
  57. deb-src http://archive.ubuntu.com/ubuntu oneiric-security main restricted
  58. deb http://archive.ubuntu.com/ubuntu oneiric-security universe
  59. deb-src http://archive.ubuntu.com/ubuntu oneiric-security universe
  60. deb http://archive.ubuntu.com/ubuntu oneiric-security multiverse
  61. deb-src http://archive.ubuntu.com/ubuntu oneiric-security multiverse
  62. deb http://archive.canonical.com/ubuntu oneiric partner
  63. deb-src http://archive.canonical.com/ubuntu oneiric partner
  64. deb http://extras.ubuntu.com/ubuntu oneiric main
  65. deb http://archive.ubuntu.com/ubuntu oneiric-proposed restricted main multiverse universe
  66. deb-src http://extras.ubuntu.com/ubuntu oneiric main" > /etc/apt/sources.list
  67.  
  68. nano /etc/apt/sources.list  
  69.  
  70. fi
  71.  
Advertisement
Add Comment
Please, Sign In to add comment