[Slackbuilds-users] What if we `source`d the version number
yalhcru at gmail.com
Tue Jan 4 21:39:07 UTC 2022
On 1/4/22, Klaatu <klaatu at mixedsignals.ml> wrote:
> Why do we define the VERSION for a package in two separate files?
> What if we replaced this line in foo.SlackBuild:
> with this instead:
> . ./$PRGNAM.info
It'd take away the ability to override VERSION in the environment. A lot
of us do this:
VERSION=1.2.3 sh foo.SlackBuild
...to attempt to build a new version of 'foo' with the existing
script. Of course this doesn't always work, but it works often enough
to be useful.
With your change, any user trying to use the script to build a newer
version would have to edit the .info file. Which is fine, but would
require changes in every automated tool that handles SBo builds (at
minimum, sbopkg and sbotools).
You could also change the .info file format, so instead of saying:
it would say:
This would allow your idea (sourcing the .info file) and the existing
practice (override VERSION in the environment) to coexist. But it would
likely break sbopkg and sbotools even worse.
More information about the SlackBuilds-users