Save packages downloaded in Puppy Package Manager (PPM)

How to do things, solutions, recipes, tutorials
Post Reply
Message
Author
User avatar
jrb
Posts: 1536
Joined: Tue 11 Dec 2007, 19:56
Location: Smithers, BC, Canada

Save packages downloaded in Puppy Package Manager (PPM)

#1 Post 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:
Attachments
downloadpkgs.pet
saves packages downloaded in PPM
(5.34 KiB) Downloaded 577 times

User avatar
Bert
Posts: 1103
Joined: Fri 30 Jun 2006, 20:09

#2 Post by Bert »

It works :)
Very nice, thanks jrb!
[url=http://pupsearch.weebly.com/][img]http://pupsearch.weebly.com/uploads/7/4/6/4/7464374/125791.gif[/img][/url]
[url=https://startpage.com/do/search?q=host%3Awww.murga-linux.com%2F][img]http://i.imgur.com/XJ9Tqc7.png[/img][/url]

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#3 Post 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.
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=69321][color=blue]Puppy Help 101 - an interactive tutorial for Lupu 5.25[/color][/url]

User avatar
jrb
Posts: 1536
Joined: Tue 11 Dec 2007, 19:56
Location: Smithers, BC, Canada

#4 Post 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

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#5 Post by Flash »

Maybe it's your browser's download manager. Are you using a different browser from SeaMonkey?
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=69321][color=blue]Puppy Help 101 - an interactive tutorial for Lupu 5.25[/color][/url]

User avatar
jrb
Posts: 1536
Joined: Tue 11 Dec 2007, 19:56
Location: Smithers, BC, Canada

#6 Post 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. :)

Bruce B

#7 Post 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?

~

User avatar
jrb
Posts: 1536
Joined: Tue 11 Dec 2007, 19:56
Location: Smithers, BC, Canada

#8 Post 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

User avatar
Béèm
Posts: 11763
Joined: Wed 22 Nov 2006, 00:47
Location: Brussels IBM Thinkpad R40, 256MB, 20GB, WiFi ipw2100. Frugal Lin'N'Win

#9 Post 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.
Time savers:
Find packages in a snap and install using Puppy Package Manager (Menu).
[url=http://puppylinux.org/wikka/HomePage]Consult Wikka[/url]
Use peppyy's [url=http://wellminded.com/puppy/pupsearch.html]puppysearch[/url]

Bruce B

#10 Post 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.

~

xmf-149
Posts: 23
Joined: Fri 02 Aug 2013, 04:00

#11 Post 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
Last edited by xmf-149 on Thu 12 Jun 2014, 02:09, edited 1 time in total.
:!: :!: :!:

User avatar
Puppus Dogfellow
Posts: 1667
Joined: Tue 08 Jan 2013, 01:39
Location: nyc

#12 Post by Puppus Dogfellow »

you can also get the pet post-install with gnewpet.

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#13 Post 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:

User avatar
Moat
Posts: 955
Joined: Tue 16 Jul 2013, 06:04
Location: Mid-mitten

#14 Post 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

Sylvander
Posts: 4416
Joined: Mon 15 Dec 2008, 11:06
Location: West Lothian, Scotland, UK

#15 Post 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].

User avatar
neerajkolte
Posts: 516
Joined: Mon 10 Feb 2014, 07:05
Location: Pune, India.

#16 Post by neerajkolte »

just bookmarking thread for future reference.
Thanks
"One of my most productive days was throwing away 1000 lines of code."
- Ken Thompson

“We tend to overestimate the effect of a technology in the short run and underestimate the effect in the long run.â€￾
- Amara’s Law.

User avatar
greengeek
Posts: 5789
Joined: Tue 20 Jul 2010, 09:34
Location: Republic of Novo Zelande

#17 Post 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

Post Reply