mirror of
https://gitlab.com/dslackw/slpkg.git
synced 2025-01-18 10:26:29 +01:00
update find argument
This commit is contained in:
parent
2f73093551
commit
c555149aa0
7 changed files with 34 additions and 26 deletions
10
CHANGELOG
10
CHANGELOG
|
@ -1,4 +1,12 @@
|
|||
Version 2.1.5-dev
|
||||
Version 2.1.6
|
||||
30-12-2014
|
||||
|
||||
[Updated] - Fix queue downloads.
|
||||
- Update find argument.
|
||||
|
||||
|
||||
|
||||
Version 2.1.5
|
||||
27-12-2014
|
||||
|
||||
[Feature] - Added slacker.it, slackonly.com, Alien's ktown, Alien's multilib,
|
||||
|
|
|
@ -244,7 +244,7 @@ Command Line Tool Usage
|
|||
-s, [repository] [package] download, build & install
|
||||
-t, [repository] [package] tracking dependencies
|
||||
-p, [repository] [package], --color=[] print package description
|
||||
-f, [package] find installed packages
|
||||
-f, [package...] find installed packages
|
||||
-n, [package] view SBo packages through network
|
||||
-i, [package...] install binary packages
|
||||
-u, [package...] upgrade binary packages
|
||||
|
|
|
@ -55,7 +55,7 @@ Optional arguments:
|
|||
-s, [repository] [package] download, build & install
|
||||
-t, [repository] [package] tracking dependencies
|
||||
-p, [repository] [package], --color=[] print package description
|
||||
-f, [package] find installed packages
|
||||
-f, [package...] find installed packages
|
||||
-n, [package] view SBo packages through network
|
||||
-i, [package...] install binary packages
|
||||
-u, [package...] upgrade binary packages
|
||||
|
|
|
@ -30,8 +30,6 @@ __version__ = "{0}.{1}.{2}".format(*__version_info__)
|
|||
__license__ = "GNU General Public License v3 (GPLv3)"
|
||||
__email__ = "d.zlatanidis@gmail.com"
|
||||
|
||||
# temponary path
|
||||
tmp = "/tmp/"
|
||||
|
||||
# Default configuration values
|
||||
slack_rel = "stable"
|
||||
|
@ -75,6 +73,7 @@ def slacke_repo(repositories):
|
|||
repositories[i] = 'slacke'
|
||||
return sub
|
||||
|
||||
tmp = "/tmp/"
|
||||
build_path = "/tmp/slpkg/build/"
|
||||
slpkg_tmp_packages = tmp + "slpkg/packages/"
|
||||
slpkg_tmp_patches = tmp + "slpkg/patches/"
|
||||
|
|
|
@ -62,7 +62,7 @@ def options():
|
|||
" -s, [repository] [package] download, build & install",
|
||||
" -t, [repository] [package] tracking dependencies",
|
||||
" -p, [repository] [package], --color=[] print package description",
|
||||
" -f, [package] find installed packages",
|
||||
" -f, [package...] find installed packages",
|
||||
" -n, [package] view SBo packages "
|
||||
"through network",
|
||||
" -i, [package...] install binary packages",
|
||||
|
|
|
@ -200,7 +200,7 @@ def main():
|
|||
PackageManager(args[1:]).reinstall()
|
||||
elif len(args) > 1 and args[0] == "-r":
|
||||
PackageManager(args[1:]).remove()
|
||||
elif len(args) == 2 and args[0] == "-f":
|
||||
elif len(args) > 1 and args[0] == "-f":
|
||||
PackageManager(args[1:]).find()
|
||||
elif len(args) == 3 and args[0] == "-p" and args[1] in repositories:
|
||||
PkgDesc(args[2], args[1], "").view()
|
||||
|
|
|
@ -230,9 +230,10 @@ class PackageManager(object):
|
|||
'''
|
||||
matching = size = 0
|
||||
print("\nPackages with matching name [ {0}{1}{2} ]\n".format(
|
||||
color['CYAN'], ''.join(self.binary), color['ENDC']))
|
||||
for match in find_package(''.join(self.binary), pkg_path):
|
||||
if ''.join(self.binary) in match:
|
||||
color['CYAN'], ', '.join(self.binary), color['ENDC']))
|
||||
for pkg in self.binary:
|
||||
for match in find_package(pkg, pkg_path):
|
||||
if pkg in match:
|
||||
matching += 1
|
||||
print("[ {0}installed{1} ] - {2}".format(
|
||||
color['GREEN'], color['ENDC'], match))
|
||||
|
@ -248,7 +249,7 @@ class PackageManager(object):
|
|||
break
|
||||
if matching == 0:
|
||||
message = "Can't find"
|
||||
pkg_not_found("", self.binary, message, "\n")
|
||||
pkg_not_found("", pkg, message, "\n")
|
||||
else:
|
||||
print("\n{0}Total found {1} matching packages.{2}".format(
|
||||
color['GREY'], matching, color['ENDC']))
|
||||
|
|
Loading…
Reference in a new issue