1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 |
- #!/bin/sh
- # This file is part of UPMS.
- # Copyright (c) 2016 ali abdul ghani <blade.vp2020@gmail.com>
- # UPMS is free software: you can redistribute it and/or modify
- # it under the terms of the GNU General Public License as published by
- # the Free Software Foundation, either version 3 of the License, or
- # (at your option) any later version.
- # UPMS is distributed in the hope that it will be useful,
- # but WITHOUT ANY WARRANTY; without even the implied warranty of
- # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- # GNU General Public License for more details.
-
- # You should have received a copy of the GNU General Public License
- # along with UPMS. If not, see <http://www.gnu.org/licenses/>.update() {
- if test $# = 0
- then
- apt-get update && apt-get upgrade
- else
- apt-get install $1
- fi
- }
- if test "$1" = "install"
- then
- apt-get install $2
- elif test "$1" = "update"
- then
- update $2
- elif test "$1" = "search"
- then
- apt-cache search $2
- elif test "$1" = "info"
- then
- apt-cache show $2
- elif test "$1" = "dup"
- then
- apt-get update && apt-get upgrade
- elif test "$1" = "remove"
- then
- apt-get purge $2
- else
- echo E: Invalid operation $1
- fi
|