Skip to content

Commit

Permalink
v3.1.4: fix a huge mess
Browse files Browse the repository at this point in the history
Signed-off-by: Kwpolska <[email protected]>
  • Loading branch information
Kwpolska committed Jul 6, 2013
1 parent 90b40ab commit 3d71566
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 11 deletions.
2 changes: 1 addition & 1 deletion PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ license=('BSD')
depends=('python' 'pyalpm>=0.5.1-1' 'python-requests' 'rsync')
options=(!emptydirs)
source=("http://pypi.python.org/packages/source/$(echo ${_pyname} | cut -c1)/${_pyname}/${_pyname}-${pkgver}.tar.gz")
md5sums=('52e5345964a1acab71b34d4c8f53365d')
md5sums=('9a0f9a6a4400882517499c26ed207e03')

package() {
cd "${srcdir}/${_pyname}-${pkgver}"
Expand Down
Binary file modified docs/pb.8.gz
Binary file not shown.
Binary file modified docs/pkgbuilder.8.gz
Binary file not shown.
4 changes: 0 additions & 4 deletions pkgbuilder/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ def safeupgrade(pkgname):
DS.fancy_msg2(_('{0} files extracted').format(extract(filename)))
os.chdir('./{0}/'.format(pkg.name))
DS.fancy_msg(_('Building {0}...').format(pkg.name))
<<<<<<< HEAD

if DS.uid == 0:
DS.fancy_warning(_('Performing a safe upgrade as root!'))
Expand All @@ -120,9 +119,6 @@ def safeupgrade(pkgname):
else:
asroot = ''
mpstatus = subprocess.call('makepkg -sicf{0}'.format(asroot), shell=True)
=======
mpstatus = subprocess.call('makepkg -sicf', shell=True)
>>>>>>> e795f5da2a630f23316a463bd6867e463c9308ba
DS.fancy_msg(_('Build finished with return code {0}.').format(mpstatus))
return mpstatus

Expand Down
20 changes: 14 additions & 6 deletions pkgbuilder/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import datetime
import subprocess
import textwrap
import sys

__all__ = ['gather_foreign_pkgs', 'list_upgradable', 'auto_upgrade']

Expand Down Expand Up @@ -188,11 +189,15 @@ def auto_upgrade(downgrade=False, vcsup=False):
yesno = input(query)

if yesno.lower().strip().startswith('y') or yesno.strip() == '':
pkgbuilder.build.safeupgrade(pkgbname)
# The return causes PKGBUILDer.main() to quit and do nothing.
# The else is unnecessary, as we drop to a regular upgrade
# if the luser says “no”.
return []
status = pkgbuilder.build.safeupgrade(pkgbname)
if status > 0:
DS.log.info('safe upgrade failed with {0}'.format(status))
sys.exit(status)
else:
# The return causes PKGBUILDer.main() to quit and do
# nothing. The else is unnecessary, as we drop to a
# regular upgrade if the luser says “no”.
return []

if DS.pacman:
targetstring = _('Targets ({0}): ').format(upglen)
Expand Down Expand Up @@ -232,6 +237,9 @@ def auto_upgrade(downgrade=False, vcsup=False):
verbosepkglists = False
DS.log.warning('VerbosePkgLists disabled, terminal is '
'not wide enough')
# string stolen from pacman
print(_('warning: insufficient columns available for '
'table display'))
else:
print('\n{0}\n'.format(targetstring.strip()))
print(fstring.format(i=headers))
Expand Down Expand Up @@ -271,4 +279,4 @@ def auto_upgrade(downgrade=False, vcsup=False):
if yesno.lower().strip().startswith('y') or yesno.strip() == '':
return upgnames
else:
return []
return []
6 changes: 6 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,15 @@
setup(name='pkgbuilder',
version='3.1.4',
description='An AUR helper (and library) in Python 3.',
keywords='arch pkgbuild',
author='Kwpolska',
author_email='[email protected]',
url='https://github.com/Kwpolska/pkgbuilder',
license='3-clause BSD',
long_description=open('./docs/README.rst').read(),
platforms='Arch Linux',
zip_safe=False,
test_suite='tests',
classifiers=['Development Status :: 6 - Mature',
'Environment :: Console',
'Intended Audience :: End Users/Desktop',
Expand All @@ -23,6 +26,9 @@
'Operating System :: POSIX :: Linux',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.1',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: System',
'Topic :: System :: Archiving :: Packaging',
'Topic :: Utilities'],
Expand Down

0 comments on commit 3d71566

Please sign in to comment.