Page 1 of 1

Save packages downloaded in Puppy Package Manager (PPM)

Posted: Tue 19 Jul 2011, 03:45
by jrb
My only objection to PPM has been that once I download and install a package it disappears! If I have to create a new save file I have to download again which on my limited bandwidth and download limit (3Gb/month) is a pain.

Recently I took a look at /usr/local/petget/downloadpkgs.sh in Drakepup to see what I could do and here it is:

Code: Select all

   #rxvt -title "Puppy Package Manager: download" -bg orange -fg black -geometry 80x10 -e wget ${DOWNLOADFROM}/${ONEFILE}
   download_file ${DOWNLOADFROM}/${ONEFILE}
   DLPKG="`basename $ONEFILE`"						#jrb 13jul11
   PUPVER=`grep DISTRO_FILE_PREFIX /etc/DISTRO_SPECS | cut -d "'" -f 2`  #jrb 17jul11
   mkdir /mnt/home/${PUPVER}_download					#jrb 13jul11
   cp /root/$DLPKG /mnt/home/${PUPVER}_download		#jrb 13jul11
Add the lines of code with #jrb on the end starting at line 170.

This will create a folder in /mnt/home with the name of the puppy you are using followed by "_download" and will copy the package you are installing into that folder.

It wouldn't surprise me if there wasn't an easier way that I am overlooking, so if you know one please let me know, but this is working well so far.

I am attaching a .pet of my modified file if you wish to try it. The usual denial of reponsibility applies. :lol:

Posted: Tue 19 Jul 2011, 10:09
by Bert
It works :)
Very nice, thanks jrb!

Posted: Tue 19 Jul 2011, 12:02
by Flash
I don't see why you had to go to all this trouble. The package manager in every Puppy I've tried always asks me before I download a .pet whether I want to open it (and install it right then) or save it as a file. If I choose to save it, I have it to install as many times as I want just by clicking on it.

Even if I choose to open and install the .pet when I download it, it is usually still to be found in my /tmp directory later on, if I want to save it.

Posted: Tue 19 Jul 2011, 13:36
by jrb
Flash wrote:The package manager in every Puppy I've tried always asks me before I download a .pet whether I want to open it (and install it right then) or save it as a file.
Even if I choose to open and install the .pet when I download it, it is usually still to be found in my /tmp directory later on, if I want to save it.
I thought I remembered that from older Puppies but I just tried installing in Drake, Lucid and Wary and the question was never asked. Also the file is downloaded to /root and fails to appear in /tmp. It is deleted immediately after install.

Perhaps someone will have to draw (or post) a picture for me if I am just missing something. :wink:

Cheers, J

Posted: Tue 19 Jul 2011, 14:00
by Flash
Maybe it's your browser's download manager. Are you using a different browser from SeaMonkey?

Posted: Tue 19 Jul 2011, 14:18
by jrb
Flash wrote:Maybe it's your browser's download manager. Are you using a different browser from SeaMonkey?
I think we're talking about two different things. Correct me if I am wrong but it sounds to me that you are downloading the .pets in your browser and then installing them. This is what I have been doing up until now because the Puppy Package Manager (Install button on the desktop) kept deleting downloads.

I find it too time consuming :x to track down .debs or .rpms and their dependencies that way. Especially when PPM will download and install all (?) the dependencies for me. :)

Posted: Tue 19 Jul 2011, 15:40
by Bruce B
Looks like a good idea to me jrb.

Of course you can't post a HowTo without critics and people who have a better way. Guess what? I have a better way.

Seriously, my only critique is that we don't know Barry will do next. The .pet package you attached might work today and mess things up on a future release.

The most important part of the HowTo was your explaining what you did and to what file.

Don't worry, after about a dozen posts the critics will find another HowTo to pick on. Anyone want to know why I don't post HowTos?

~

Posted: Tue 19 Jul 2011, 15:58
by jrb
Bruce B wrote:we don't know Barry will do next. The .pet package you attached might work today and mess things up on a future release.
Right you are Bruce. I attached the .pet for people who aren't comfortable editing files. If it quits working in a future release, or worse, I trust someone will let me know and I will withdraw the .pet.

As for people having a better way - I'm always happy to learn. :D

Posted: Tue 19 Jul 2011, 20:47
by Béèm
@Flash,
When selecting a package from PPM, I never got the question if I would install or download that selected package.
This is one of the reasons I don't use PPM often.

Posted: Tue 19 Jul 2011, 21:12
by Bruce B
jrb wrote:As for people having a better way - I'm always happy to learn. :D
A better way?

The better way I was thinking of would be a distraction from the intent of your howto. It would demand its own HowTo and a very courageous OP.

I hope you understand by now, if you didn't earlier, that HowTos are subject to the most rigorous peer review. If there is an error, we will find it, argue over it and fix the HowTo.

Such is life I guess.

~

Posted: Tue 15 Apr 2014, 00:30
by xmf-149
no actually i was just looking this up but i found this and you pointed me to the correct file but...
it is simpler to go down farther to before verify/installpkg.sh is called and add

Code: Select all

mkdir -p /tmp/packs;cp -f /root/$DLPKG /tmp/packs
also it really would be nice to have a button (again?) to do this

speaking of the interface to Puppy Package Manager i will just mention here that i was using the classic ui and changed the first nested vbox to

Code: Select all

<vbox space-expand=\"0\" space-fill=\"0\">
because the resize was bugging me and then i also had to edit the following vbox to

Code: Select all

<vbox space-expand=\"1\" space-fill=\"1\">
also i added ' &' after 'installpreview.sh' to allow the main interface to update while that dialog is displayed
just before posting this i found a new thread about this so ill just link it here, for the search engines. i am using the same pup as the original poster, and the more info button is indeed an option but it is slower, then i read farther and they seem to have updated woof with a button but since i wrote all this im posting it anyway and using it for now

Posted: Mon 21 Apr 2014, 08:22
by Puppus Dogfellow
you can also get the pet post-install with gnewpet.

Posted: Mon 21 Apr 2014, 14:51
by Flash
I owe everyone an apology,
I just realized that I've been talking about the .pets that I downloaded from attachments to the forum, not the ones in PPM. :oops:

Posted: Mon 21 Apr 2014, 23:10
by Moat
xmf-149 wrote: also it really would be nice to have a button (again?) to do this...

...and they seem to have updated woof with a button
Yes - for those that may have missed MochiMoppel's great little script tweak that adds a download button to the PPM - http://www.murga-linux.com/puppy/viewtopic.php?p=763951

Bob

Posted: Tue 22 Apr 2014, 00:26
by Sylvander
Moat wrote:MochiMoppel's great little script tweak that adds a download button to the PPM - http://www.murga-linux.com/puppy/viewtopic.php?p=763951
Made those changes [in Slacko-5.5.91] and it appears to be ready to work [the "download only" button is there, but I have no need to use it yet].

Posted: Sun 18 May 2014, 07:27
by neerajkolte
just bookmarking thread for future reference.
Thanks

Posted: Thu 22 May 2014, 10:21
by greengeek
If you end up with a download of a whole bunch of debs and want to assemble them into a single package ready for install or sfs build there is a good reference here:
http://ns1.murga-projects.com/puppy/vie ... ef1#760502