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