mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2025-01-30 20:34:38 +01:00
added config option
This commit is contained in:
parent
540f04340d
commit
a46cdc0b50
5 changed files with 24 additions and 3 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
Version 2.4.1
|
||||||
|
03-06-2015
|
||||||
|
|
||||||
|
[Feature] - Added option to upgrade only the distribution packages installed.
|
||||||
|
|
||||||
|
[Updated] - Fixed upgrade packages.
|
||||||
|
- Fixed checksum on/off.
|
||||||
|
|
||||||
|
|
||||||
Version 2.4.0
|
Version 2.4.0
|
||||||
02-06-2015
|
02-06-2015
|
||||||
|
|
||||||
|
|
|
@ -81,3 +81,8 @@ WGET_OPTIONS=-c -N
|
||||||
# Automatically synchronizes the command 'slackpkg update' with
|
# Automatically synchronizes the command 'slackpkg update' with
|
||||||
# 'slpkg -c slack --upgrade'.
|
# 'slpkg -c slack --upgrade'.
|
||||||
SLACKPKG_LOG=on
|
SLACKPKG_LOG=on
|
||||||
|
|
||||||
|
# This option applies only to the distribution upgrade and repository
|
||||||
|
# slack. If you want to update only packages that are installed
|
||||||
|
# choose 'on'. Default is 'off'.
|
||||||
|
ONLY_INSTALLED=off
|
||||||
|
|
|
@ -125,7 +125,8 @@ class MetaData(object):
|
||||||
'DEL_DEPS': 'off',
|
'DEL_DEPS': 'off',
|
||||||
'USE_COLORS': 'on',
|
'USE_COLORS': 'on',
|
||||||
'WGET_OPTIONS': '-c -N',
|
'WGET_OPTIONS': '-c -N',
|
||||||
'SLACKPKG_LOG': 'on'
|
'SLACKPKG_LOG': 'on',
|
||||||
|
'ONLY_INSTALLED': 'off'
|
||||||
}
|
}
|
||||||
|
|
||||||
default_repositories = ['slack', 'sbo', 'rlw', 'alien', 'slacky', 'studio',
|
default_repositories = ['slack', 'sbo', 'rlw', 'alien', 'slacky', 'studio',
|
||||||
|
@ -162,6 +163,7 @@ class MetaData(object):
|
||||||
use_colors = _conf_slpkg['USE_COLORS']
|
use_colors = _conf_slpkg['USE_COLORS']
|
||||||
wget_options = _conf_slpkg['WGET_OPTIONS']
|
wget_options = _conf_slpkg['WGET_OPTIONS']
|
||||||
slackpkg_log = _conf_slpkg['SLACKPKG_LOG']
|
slackpkg_log = _conf_slpkg['SLACKPKG_LOG']
|
||||||
|
only_installed = _conf_slpkg['ONLY_INSTALLED']
|
||||||
|
|
||||||
# Remove any gaps
|
# Remove any gaps
|
||||||
repositories = [repo.strip() for repo in repositories]
|
repositories = [repo.strip() for repo in repositories]
|
||||||
|
|
|
@ -54,7 +54,8 @@ class Config(object):
|
||||||
'DEL_DEPS',
|
'DEL_DEPS',
|
||||||
'USE_COLORS',
|
'USE_COLORS',
|
||||||
'WGET_OPTIONS',
|
'WGET_OPTIONS',
|
||||||
'SLACKPKG_LOG'
|
'SLACKPKG_LOG',
|
||||||
|
'ONLY_INSTALLED'
|
||||||
]
|
]
|
||||||
read_conf = Utils().read_file(self.config_file)
|
read_conf = Utils().read_file(self.config_file)
|
||||||
for line in read_conf.splitlines():
|
for line in read_conf.splitlines():
|
||||||
|
|
|
@ -193,6 +193,10 @@ class ArgParse(object):
|
||||||
BinaryInstall(pkg_upgrade(self.args[1], skip),
|
BinaryInstall(pkg_upgrade(self.args[1], skip),
|
||||||
self.args[1]).start(True)
|
self.args[1]).start(True)
|
||||||
elif self.args[1] == 'slack':
|
elif self.args[1] == 'slack':
|
||||||
|
if _m.only_installed in ['on', 'ON']:
|
||||||
|
BinaryInstall(pkg_upgrade('slack', skip),
|
||||||
|
'slack').start(True)
|
||||||
|
else:
|
||||||
Patches(skip).start()
|
Patches(skip).start()
|
||||||
elif self.args[1] == 'sbo':
|
elif self.args[1] == 'sbo':
|
||||||
SBoInstall(sbo_upgrade(skip)).start(True)
|
SBoInstall(sbo_upgrade(skip)).start(True)
|
||||||
|
|
Loading…
Add table
Reference in a new issue