You are not logged in.

#176 2010-01-25 04:38:12

sHyLoCk
Member
From: /dev/null
Registered: 2009-06-19
Posts: 1,197

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

handy wrote:

I'm already in love with packer, it has already replaced yaourt on my system. smile

Same.


~ Regards,
sHy
ArchBang: Yet another Distro for Allan to break.
Blog | GIT | Forum (。◕‿◕。)

Offline

#177 2010-01-25 05:21:21

n0dix
Member
Registered: 2009-09-22
Posts: 956

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

Great contribution. Continue with the good work!!!

Offline

#178 2010-01-25 08:48:01

bruenig
Member
Registered: 2007-05-20
Posts: 175

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

handy wrote:

I'm glad I stumbled on this thread. smile

Thanks bruenig for making packer.

I just installed packer & ran packer -Syu, it was certainly quicker than the -Syu --aur I am used to.

When it got to the AUR upgrade the following happened even though I have IgnorePkg = nerolinux in pacman.conf:


:: Starting full aur upgrade...
resolving dependencies...

Aur Targets    (1): nerolinux
Pacman Targets (1): rpmextract

Proceed with installation? [Y/n] n


I thought that packer abides by pacman.conf, at least in the IgnorePkg instance.  Am I missing something here?

Anyway, even if it doesn't, I'm already in love with packer, it has already replaced yaourt on my system. smile

This is supposed to work. So there must be a bug. I will try to find it. You might also try packer --ignore nerolinux -Syu for giggles, although that should fail if IgnorePkg is failing (unless it is a parsing issue perhaps?).

Offline

#179 2010-01-25 09:54:00

handy
Member
From: Oz
Registered: 2008-03-26
Posts: 719

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

bruenig wrote:

This is supposed to work. So there must be a bug. I will try to find it. You might also try packer --ignore nerolinux -Syu for giggles, although that should fail if IgnorePkg is failing (unless it is a parsing issue perhaps?).

I just used packer --ignore nerolinux -Syu & it worked smile :

:: Starting full system upgrade...
local database is up to date
:: Synchronizing aur database...
aur                                         21  21 [###############################################] 100%
:: Starting full aur upgrade...
warning: nerolinux 3.5.3.1-1: ignoring package upgrade (3.5.3.1-1 => 4.0.0.0-2)
local database is up to date

_______________

I hope that helps your tracking bruenig?

Last edited by handy (2010-01-25 09:55:12)


I used to be surprised that I was still surprised by my own stupidity, finding it strangely refreshing.
Well, now I don't find it refreshing.
I'm over it!

Offline

#180 2010-01-25 11:08:45

Mikko777
Member
From: Suomi, Finland
Registered: 2006-10-30
Posts: 837

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

j2902 wrote:

I've got a question / feature request.
If packer doesn't recognize the argument pattern, eg, -Rns, could it just call pacman with those arguments?
Note: I got this to work by changing line 412 to

 -*) runasroot pacman-color $@ ; exit ;;

This is the feature I was missing also smile

alias pacman = packer roll

Offline

#181 2010-01-25 12:14:05

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 3,440
Website

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

Mikko777 wrote:

alias pacman = packer

That's a fine idea, I'm just surprised at how many people are requesting it. yikes

Here is how I do my package manager aliases. Do most people do it differently? I don't want to remember all of those "letter" arguments. tongue

# Shortcuts for package commands
alias archinstall="packer -S"
alias archupdate="packer -Syu"
alias archsearch="packer -Ss"
alias archinfo="packer -Si"
alias archremove="sudo pacman-color -Rs"
alias archrip="sudo pacman-color -Rd"
alias archclean="sudo pacman-color -Sc"
alias archsync="sudo pacman-color -Syy"
alias archlist="pacman-color -Ql"
alias archwhich="pacman-color -Qo"
alias archpackages="pacman-color -Qq"
alias archpackagesaur="pacman-color -Qmq"
alias archpackagesorphans="pacman-color -Qdtq"
alias archpackagestoplevel="pacman-color -Qetq"
alias archpackagesinstalledbyme="pacman-color -Qeq"

archpackagesofficial()
{
  pacman-color -Qq | grep -v "`archpackagesaur`"
}

archmirrorupdate()
{
  echo Updating list of mirrors by speed and freshness...
  sudo reflector --latest 6 --rank /etc/pacman.d/mirrorlist.all > /tmp/mirrorlist
  sudo mv /etc/pacman.d/mirrorlist /tmp/mirrorlist.OLD
  sudo cp /tmp/mirrorlist /etc/pacman.d/mirrorlist
  archsync
}

Offline

#182 2010-01-25 15:15:20

bruenig
Member
Registered: 2007-05-20
Posts: 175

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

handy wrote:
bruenig wrote:

This is supposed to work. So there must be a bug. I will try to find it. You might also try packer --ignore nerolinux -Syu for giggles, although that should fail if IgnorePkg is failing (unless it is a parsing issue perhaps?).

I just used packer --ignore nerolinux -Syu & it worked smile :

:: Starting full system upgrade...
local database is up to date
:: Synchronizing aur database...
aur                                         21  21 [###############################################] 100%
:: Starting full aur upgrade...
warning: nerolinux 3.5.3.1-1: ignoring package upgrade (3.5.3.1-1 => 4.0.0.0-2)
local database is up to date

_______________

I hope that helps your tracking bruenig?

Yes, it does. It must mean that I am parsinng the IgnorePkg line out of pacman.conf poorly. Can you paste the exact line(s) in your pacman.conf that you are specifying IgnorePkg on. Right now, packer assumes that all IgnorePkg lines look something like this: IgnorePkg = foo bar blah pkg3. So IgnorePkg followed by space followed by equal sign followed by space, then a list of space-delimited package arguments. But perhaps this is wrong or just not actually implemented correctly smile.

Last edited by bruenig (2010-01-25 15:17:04)

Offline

#183 2010-01-25 21:28:48

handy
Member
From: Oz
Registered: 2008-03-26
Posts: 719

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

@bruenig: I just noticed when I went to copy the line you want to see in pacman.conf that there is a leading space before IgnorePkg:

IgnorePkg      = nerolinux

I'll just do an packer -Syu & see what happens, since I've removed the space.

Yep, it works now, so it looks like the leading space was the problem.

Last edited by handy (2010-01-25 21:29:15)


I used to be surprised that I was still surprised by my own stupidity, finding it strangely refreshing.
Well, now I don't find it refreshing.
I'm over it!

Offline

#184 2010-01-25 21:30:43

tillmann
Member
Registered: 2010-01-21
Posts: 4

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

One problem:

~ > packer -Syu --auronly --devel
:: Synchronizing aur database...
 aur                                         18  18 [####################] 100%
/tmp/packeroutput-1000: Line 35: error: Command not found.
~ >

(Just for the fun of it) I linked /bin/echo to /bin/error resulting in:

~ > packer -Su --auronly --devel
:: Synchronizing aur database...
 aur                                         18  18 [####################] 100%
Unknown or invalid CARCH=
~ >

This file (/tmp/packeroutput-1000) seems to be the PKGBUILD of the package virtualbox-sun:

    31    case "$CARCH" in
    32        i686|i[3-5]86) _arch='x86';;
    33        x86_64|amd64) _arch='amd64'; md5sums[0]='0cb94f14427827dbd3cef1b2a60f74f5';;
    34        # The following should not happen; provided you're using 'makepkg' ;)
    35        *) error "Unknown or invalid CARCH=$CARCH"; exit 1
    36    esac

The funny thing is: a packer -S virtualbox-sun updates that very package without problems.
So there should be nothing wrong with the package right?

Nevertheless, packer has replaced yaourt for me...

Offline

#185 2010-01-25 23:03:52

bruenig
Member
Registered: 2007-05-20
Posts: 175

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

tillmann wrote:

One problem:

~ > packer -Syu --auronly --devel
:: Synchronizing aur database...
 aur                                         18  18 [####################] 100%
/tmp/packeroutput-1000: Line 35: error: Command not found.
~ >

(Just for the fun of it) I linked /bin/echo to /bin/error resulting in:

~ > packer -Su --auronly --devel
:: Synchronizing aur database...
 aur                                         18  18 [####################] 100%
Unknown or invalid CARCH=
~ >

This file (/tmp/packeroutput-1000) seems to be the PKGBUILD of the package virtualbox-sun:

    31    case "$CARCH" in
    32        i686|i[3-5]86) _arch='x86';;
    33        x86_64|amd64) _arch='amd64'; md5sums[0]='0cb94f14427827dbd3cef1b2a60f74f5';;
    34        # The following should not happen; provided you're using 'makepkg' ;)
    35        *) error "Unknown or invalid CARCH=$CARCH"; exit 1
    36    esac

The funny thing is: a packer -S virtualbox-sun updates that very package without problems.
So there should be nothing wrong with the package right?

Nevertheless, packer has replaced yaourt for me...

packer -S packer. Try now.

Last edited by bruenig (2010-01-25 23:04:19)

Offline

#186 2010-01-25 23:49:47

bruenig
Member
Registered: 2007-05-20
Posts: 175

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

handy wrote:

@bruenig: I just noticed when I went to copy the line you want to see in pacman.conf that there is a leading space before IgnorePkg:

IgnorePkg      = nerolinux

I'll just do an packer -Syu & see what happens, since I've removed the space.

Yep, it works now, so it looks like the leading space was the problem.

Changed glob to read '^ *IgnorePkg'. So leading space should work now.

Offline

#187 2010-01-26 00:34:37

brendan
Member
From: UK
Registered: 2009-05-16
Posts: 130
Website

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

Seems like some good work there bruenig! Cheers.

I was very impressed with the speed at which it searches the AUR. I've now decided that I'd try it to install kernel26zen-git, if that works then yaourt can wave byebye!

Offline

#188 2010-01-26 00:39:42

handy
Member
From: Oz
Registered: 2008-03-26
Posts: 719

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

bruenig wrote:
handy wrote:

@bruenig: I just noticed when I went to copy the line you want to see in pacman.conf that there is a leading space before IgnorePkg:

IgnorePkg      = nerolinux

I'll just do an packer -Syu & see what happens, since I've removed the space.

Yep, it works now, so it looks like the leading space was the problem.

Changed glob to read '^ *IgnorePkg'. So leading space should work now.

Thanks. smile

Many of us often add & remove comments to lines so a space or two can often occur.  At least in my config files anyway. wink

[Edit:] By the way bruenig, I started a thread on packer at the Ubuntu forums nearly 24 hours ago (as of this writing).  It is helping other Arch users to get to know that packer exists.  Quite a few users of the Ubuntu forum are Arch users these days. smile

I also made a thread at ostalk.org, but there aren't many of us over there.

Last edited by handy (2010-01-26 08:58:21)


I used to be surprised that I was still surprised by my own stupidity, finding it strangely refreshing.
Well, now I don't find it refreshing.
I'm over it!

Offline

#189 2010-01-26 10:32:40

mikkie
Member
Registered: 2009-11-10
Posts: 52

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

bruenig

My sincere admiration. This is really fast. Gonna use it instead of yaourt from now on.

Offline

#190 2010-01-26 13:01:30

sHyLoCk
Member
From: /dev/null
Registered: 2009-06-19
Posts: 1,197

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

Is there any way you could add a warning for flagged-out-of-date packages? I just tried installing an outdated package and it didn't show  any warning like yaourt did. This feature could be helpful.


~ Regards,
sHy
ArchBang: Yet another Distro for Allan to break.
Blog | GIT | Forum (。◕‿◕。)

Offline

#191 2010-01-26 21:46:39

bruenig
Member
Registered: 2007-05-20
Posts: 175

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

I changed the way packer handles tmp files. Before it had just one tmpfile and would download stuff and overwrite as needed. But this required me to download the same info file or the same pkgbuild sometimes 2 or 3 times during an execution. This is no good. So I have now set it up where there is a dir full of downloaded info and PKGBUILD, so that the program can just see if such files exist later during execution and use them instead of fetching them all over again.

So in sum, speed increase because of decreased reliance on downloading files over and over again.

Also, I modified the -Su handling to just use the same code -S was using which decreased the size of the program by 60 lines which should obviously again make it faster and easier to maintain.

Now, that I have done that, I should be able to work on sHyLoCk's stuff.

PS: Please test the program and see if everything appears to be working as previously desired. I have done so and it appears to, but that is just me.

Last edited by bruenig (2010-01-26 21:48:32)

Offline

#192 2010-01-27 00:27:55

mikkie
Member
Registered: 2009-11-10
Posts: 52

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

No bugs here for now. This thing becomes faster and faster.

Offline

#193 2010-01-27 06:13:03

MajorTom
Member
From: Canada, GTA
Registered: 2008-09-12
Posts: 58

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

I think auto-setting --auronly when calling from -Su was a good move. Later on it'd be nice if packer's help showed some more detailed info on that and other functionality.

BTW: I'm still addicted to packer -S packer and reading packer's git commit history.

Offline

#194 2010-01-27 07:21:30

bruenig
Member
Registered: 2007-05-20
Posts: 175

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

sHyLoCk wrote:

Is there any way you could add a warning for flagged-out-of-date packages? I just tried installing an outdated package and it didn't show  any warning like yaourt did. This feature could be helpful.

Added as a warning that goes where the up-to-date reinstallation warning goes.

Offline

#195 2010-01-27 09:01:16

sHyLoCk
Member
From: /dev/null
Registered: 2009-06-19
Posts: 1,197

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

bruenig wrote:
sHyLoCk wrote:

Is there any way you could add a warning for flagged-out-of-date packages? I just tried installing an outdated package and it didn't show  any warning like yaourt did. This feature could be helpful.

Added as a warning that goes where the up-to-date reinstallation warning goes.

Thanks! Perfect, one line warning just before confirmation. Great job! smile


~ Regards,
sHy
ArchBang: Yet another Distro for Allan to break.
Blog | GIT | Forum (。◕‿◕。)

Offline

#196 2010-01-27 12:41:59

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 3,440
Website

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

MajorTom wrote:

I think auto-setting --auronly when calling from -Su was a good move. Later on it'd be nice if packer's help showed some more detailed info on that and other functionality.

You might enjoy helping update the packer wiki! http://wiki.github.com/bruenig/packer/ I've been enjoying updating it. wink Add whatever you think people will find useful.

I suppose it might be a little tricky to tell just how much information to put in a packer manual, because, the "packer" script is so small and well documented, it may be easier for people to check read the source.

Offline

#197 2010-01-27 13:06:47

rson451
Member
From: Annapolis, MD USA
Registered: 2007-04-15
Posts: 1,233
Website

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

Just a suggestion, formatting the options on the wiki page more like a man page would make finding the options easier.  It's more familiar for most than the current format.


archlinux - please read this and this — twice — then ask questions.
--
http://rsontech.net | http://github.com/rson

Offline

#198 2010-01-27 13:51:09

JayJay
Member
Registered: 2008-09-25
Posts: 6

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

thats the tool i am waiting for (since using Arch Linux). cool

Great work bruenig!

JJ

Offline

#199 2010-01-27 16:29:30

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 3,440
Website

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

rson451 wrote:

Just a suggestion, formatting the options on the wiki page more like a man page would make finding the options easier.

Wiki updated.

Last edited by drcouzelis (2010-01-27 16:29:45)

Offline

#200 2010-01-27 16:33:58

barzam
Member
From: Sweden
Registered: 2009-01-27
Posts: 277

Re: packer - New bash aur+pacman wrapper (replaces poorly written yaourt)

I get the terminal too wide error when editing the pkgbuild, I guess this is a system wide error in Vi that I haven't bothered to fix. Any wey to make packer use something else (vim for example) or a solution to the Vi thingy?

Great package btw, with the separate pacdiffviewer package I can dump yaourt for now. Thanks!

Offline

Board footer

Powered by FluxBB