LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   autoslackpkg - a way to automate slackpkg (https://www.linuxquestions.org/questions/slackware-14/autoslackpkg-a-way-to-automate-slackpkg-4175664953/)

TSquaredF 12-24-2019 02:24 PM

Well, I'm only managing three systems, but each has updated flawlessly with autoslackpkg since my original problem. I don't know yet what caused that blowup, but it has not repeated. Thank you, Chuck56, for posting such a helpful tool.

dchmelik 01-09-2020 02:44 AM

I'd like to try it, but...

Code:

root@0.cosmos:~# installpkg autoslackpkg-0.8-noarch-1_SBo.tgz
Verifying package autoslackpkg-0.8-noarch-1_SBo.tgz.
Unable to install autoslackpkg-0.8-noarch-1_SBo.tgz:  tar archive is corrupt (tar returned error code 2)

I tried on two different computers, downloaded it a second time, tried both again... always same result. :(

individual 01-09-2020 04:37 AM

Quote:

Originally Posted by dchmelik (Post 6076225)
I'd like to try it, but...

Code:

root@0.cosmos:~# installpkg autoslackpkg-0.8-noarch-1_SBo.tgz
Verifying package autoslackpkg-0.8-noarch-1_SBo.tgz.
Unable to install autoslackpkg-0.8-noarch-1_SBo.tgz:  tar archive is corrupt (tar returned error code 2)

I tried on two different computers, downloaded it a second time, tried both again... always same result. :(

The problem is it's only a tar archive. It's not actually gzipped.
Code:

~: file autoslackpkg-0.8.tar.gz
autoslackpkg-0.8.tar.gz: POSIX tar archive (GNU)


Chuck56 01-09-2020 09:19 AM

Quote:

Originally Posted by dchmelik (Post 6076225)
Code:

Unable to install autoslackpkg-0.8-noarch-1_SBo.tgz:  tar archive is corrupt (tar returned error code 2)

Sorry about the corrupt SBo.tgz. I rebuilt it and ran "file" against the new package:
Code:

me@server:$ file autoslackpkg-0.8-noarch-1_SBo.tgz
autoslackpkg-0.8-noarch-1_SBo.tgz: gzip compressed data, last modified: Thu Jan  9 15:07:05 2020, max compression, from Unix, original size 92160

I reposted the SBo file at: https://www.go4it2day.com/downloads/...arch-1_SBo.tgz

Hope that works better. I'm headed out for the morning for some fun in the snow and will check back later this afternoon.

Skaendo 01-09-2020 11:57 AM

I don't use "tools" like these, but I do like seeing people use their creative side and reading about what they are creating.

I have one comment, and it's not about your work, but I think that technically you're not supposed to use the _SBo $TAG on packages that you are distributing. I just don't want to see you get yelled at by Willy :D (J/K, Willy wouldn't yell at you). But I think that just to be on the safe side, you should probably change the $TAG in your script.

Keep Hacking!

montagdude 01-09-2020 12:06 PM

Quote:

Originally Posted by Skaendo (Post 6076386)
I have one comment, and it's not about your work, but I think that technically you're not supposed to use the _SBo $TAG on packages that you are distributing. I just don't want to see you get yelled at by Willy :D

Lawsuit incoming! :rolleyes:

Tonus 01-09-2020 01:56 PM

autoslackpkg - a way to automate slackpkg
 
Hi there, any plans for grub?
Since it takes whatever kernels are installed, it could be as simple as
Code:

grub-mkconfig -o /boot/grub/grub.cfg
Saying the target might have to be configured.

That's how it works here. Perhaps more experts folks could step in and add hints?

Chuck56 01-09-2020 07:43 PM

Quote:

Originally Posted by Tonus (Post 6076437)
Hi there, any plans for grub? ...

I've never used GRUB so that makes it a bit tough for me to script. I'm not ruling it out just waiting to see if the script gains more traction and users.

Chuck56 01-09-2020 07:45 PM

Quote:

Originally Posted by Skaendo (Post 6076386)
...I think that technically you're not supposed to use the _SBo $TAG on packages that you are distributing...

You're right! I plan to submit the script to SBo, eventually.

dchmelik 01-10-2020 01:18 AM

I still got the same problem, which seemed to be I can't download from that site with a normal web browser... used wget, then the package worked. I ran autoslackpkg and it said too many arguments (but I had written zero of them)... default behaviour should be a sumamry... preferably also a manual (man) page. After typing 'autslackpkg --help' then more arguments, I'm just at a loss how to use it...

Chuck56 01-10-2020 09:28 PM

Quote:

Originally Posted by dchmelik (Post 6076587)
I still got the same problem, which seemed to be I can't download from that site with a normal web browser... used wget, then the package worked. I ran autoslackpkg and it said too many arguments (but I had written zero of them)... default behaviour should be a sumamry... preferably also a manual (man) page. After typing 'autslackpkg --help' then more arguments, I'm just at a loss how to use it...

My site is using mod_deflate and I didn't have the no-gzip setting for the downloads directory. It should be fixed now. Compressing already compressed files is bad form on my part.

Not sure what the "too many arguments" error is all about. Try: autoslackpkg -h overview

If that doesn't work maybe the wget download was wonky and needs a redo.

dchmelik 01-10-2020 09:41 PM

Quote:

Originally Posted by Chuck56 (Post 6076926)
Not sure what the "too many arguments" error is all about. Try: autoslackpkg -h overview

I.e., when one only types 'autoslackpkg' (no arguments) zero arguments is not too many arguments so shouldn't say that rather than perhaps giving the overview--what almost all commands do (or otherwise kind of troll you by saying what to type for help then forcing you type that just to get an idea what it's about... it's good if they give an overview if there are no arguments and a longer overview if you add '-h' or '--help,' but overviews aren't going to be different there's no reason to make you type an argument than just make it the default output when you're not telling it to do anything.)

Chuck56 01-10-2020 09:46 PM

I wonder if there's something in your shell environment that might be in play. Here's what I see when I enter "autoslackpkg"

Code:

root@desktop:~# autoslackpkg

Usage: autoslackpkg [-h|m|s|v] [argument]
  [-h] help    - requires argument
                overview | blacklist | elilo | lilo | mkinitrd
  [-m] mode    - requires argument
                dialog | batch
  [-s] section - requires argument
                update | install-new | upgrade-all | install-kernel
                | clean-system | remove-kernel | new-config
  [-v] version - release version


dchmelik 01-10-2020 09:56 PM

Quote:

Originally Posted by Chuck56 (Post 6076929)
I wonder if there's something in your shell environment that might be in play.

I think you're right; sorry (got the normal output, you showed above, on my server; ) should've posted this full output I got on my laptop, actually.

Code:

root@0.microcosmos:~# autoslackpkg
/usr/sbin/autoslackpkg: line 114: [: too many arguments
/usr/sbin/autoslackpkg: line 124: DIALOG: unbound variable

However I haven't really started using it yet, because apparently the default is install packages one doesn't have installed--like X11 on a virtual private server (VPS, don't want them installed, unused, not always enough room)--and 'slackpkg clean-system'--which would remove everything I built from SlackBuilds.org/etc. I'd guess there's a way to disable/alter that behaviour.

Chuck56 01-10-2020 10:05 PM

That's where your /etc/slackpkg/blacklist comes into play. You can exclude X11 files, SBo files and others from consideration.


All times are GMT -5. The time now is 05:35 PM.