update improved
This commit is contained in:
parent
3a91a7527e
commit
b230642432
2 changed files with 9 additions and 1 deletions
|
@ -102,6 +102,7 @@ function isMate () {
|
|||
|
||||
#
|
||||
# system update
|
||||
#TODO: add pip, npm, gem
|
||||
#
|
||||
function updateSystem () {
|
||||
typeset ret_code
|
||||
|
@ -255,6 +256,8 @@ function installAppFromArchive () {
|
|||
# input : package manager, package name
|
||||
# package manager available : apt, pip, npm, gem, snap
|
||||
# TODO: add apm, flatpak, umake?
|
||||
# TODO: update npm before update/install pkg
|
||||
# FIXME: use pkg instead of $*
|
||||
#
|
||||
function installPackage () {
|
||||
typeset pkg="$*"
|
||||
|
@ -672,6 +675,7 @@ function usage () {
|
|||
printf "Usage : yggdrasil [options]\n"
|
||||
printf " -a : install all apps (see doc for more details\n"
|
||||
printf " -c : install gtk themes and icons\n"
|
||||
printf " -u : update system (apt,snap,...)\n"
|
||||
printf " -v : show verison number\n"
|
||||
printf " -h : show help & informations\n"
|
||||
}
|
|
@ -38,7 +38,7 @@ echo "--[ Yggdrasil log ]--[ "$cDate" ]--[ "$cTime" ]-----------------------" >>
|
|||
#
|
||||
# arguments/options management with getopts
|
||||
#
|
||||
while getopts ":h,v,a,c,t" option; do
|
||||
while getopts ":h,v,a,c,t,u" option; do
|
||||
case "$option" in
|
||||
t) #test purpose only
|
||||
installNightly
|
||||
|
@ -73,6 +73,10 @@ while getopts ":h,v,a,c,t" option; do
|
|||
installThemes
|
||||
exit
|
||||
;;
|
||||
u)
|
||||
updateSystem
|
||||
exit
|
||||
;;
|
||||
h) # display help
|
||||
usage
|
||||
exit
|
||||
|
|
Loading…
Reference in a new issue