[Slackbuilds-users] Respect Content-disposition header always?

Erich Ritz erich.public at protonmail.com
Tue Mar 1 21:52:50 UTC 2022


------- Original Message -------

On Tuesday, March 1st, 2022 at 3:27 PM, B Watson <yalhcru at gmail.com> wrote:

> On 3/1/22, Erich Ritz via SlackBuilds-users
>
> slackbuilds-users at slackbuilds.org wrote:
>
> > Based on this commit:
> >
> > http://git.slackbuilds.org/slackbuilds/commit/?id=59ddd1a2287f3432c9bf1e3f690c8d17c9fcef5d
> >
> > I guess it's now SBo policy that downloads must respect Content-disposition?
> >
> > Or I missed that it always was?
>
> Yeah, that's something we've started doing systematically, because it
> makes life easier for us when we're doing mass-rebuilds. It also makes
> life easier for users, who persist in using whatever tool they feel
> like to download the file (which results in emails from the users when
> the script fails because of the filename...)
>
> A while back there was a post to the mailing list about it (like, a
> few years back). Probably one of us should write up a FAQ and link it
> from the submissions section on the web site.
>
> > (note that wget --content-disposition downloads this file as
> > pop-os-sysfs-class-0.1.3-1-gab63e7f.tar.gz).
> >
> > I've been (ab)using github's feature that you can name a download file
> > whatever you want, with the purpose of making the SlackBuild much easier to
> > write.
>
> Please don't do that...

I hear you loud and clear.  Turns out the only 2 places I've done it were on crate files.  The 1 you fixed and 1 I have not yet submitted waiting for 15.0 to open for new submissions.  I fixed it as well.

>
> Plus, it doesn't make it that much easier: your script still
> has to refer to the extracted directory by the same name as the
> content-disposition would have given you.

In my case I didn't, because I am using:
mkdir $SPECIAL_DIR && tar xvf $CRATE_FILE -C $SPECIAL_DIR --strip-components=1.

... all so I can follow cargo's conventions!

Thanks for the clarification.

Erich


More information about the SlackBuilds-users mailing list