eopkg 393 B

1234567891011121314151617181920212223242526272829303132
  1. #!/bin/sh
  2. install() {
  3. if test "$1" = "--reinstall"
  4. then
  5. apt-get remove $2
  6. apt-get install $2
  7. else
  8. apt-get install $1
  9. }
  10. if test "$1" = "install"
  11. then
  12. install $2 $3
  13. elif test "$1" = "update"
  14. then
  15. apt-get update
  16. elif test "$1" = "info"
  17. then
  18. apt-cache show $2
  19. elif test "$1" = "upgrade"
  20. then
  21. apt-get upgrade
  22. elif test "$1" = "remove"
  23. then
  24. apt-get purge $2
  25. else
  26. echo E: Invalid operation $1
  27. fi