Closed Rylon closed 5 years ago
From the API you can choose the output name with the .output(...) method, iirc.
From the CLI, you can choose this with the ‘-p’ flag.
(I’m on my phone so it’s hard to verify — lemme know if either of these works.)
On Wed, Aug 7, 2019 at 8:17 AM Ryan Conway notifications@github.com wrote:
Hi @jordansissel https://github.com/jordansissel
We've encountered an unusual issue with the Debian Epoch being missing from the resulting .deb filename. Although the Deb package type supports epoch, when the filename is generated via .to_s(), it is not included in the default format, which I can see is determined here:
https://github.com/jordansissel/fpm/blob/master/lib/fpm/package/deb.rb#L1043-L1047
I can see that this method supports passing in a format, defaulting to: "NAME_FULLVERSION_ARCH.EXTENSION".
We'd like to change it to match the Debian packaging spec: "NAME_EPOCH:FULLVERSION_ARCH.EXTENSION".
Is it possible to set this via some mechanism, or do we need to monkey patch?
Behind the scenes we're using fpm-cookery and monkey patching in the recipe does work, but feels wrong :D
Thanks for your time :)
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/jordansissel/fpm/issues/1659?email_source=notifications&email_token=AABAF2XERX4EO2UUJVZZFEDQDLRPFA5CNFSM4IKBRJU2YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HD5SQAA, or mute the thread https://github.com/notifications/unsubscribe-auth/AABAF2RVMI5DPPSKGXRZN5DQDLRPFANCNFSM4IKBRJUQ .
Thanks @jordansissel yeah that should work too, however we were hoping to generate the format automatically based on the metadata, rather than specifying it statically. The only thing wrong with the default pattern (for .deb
at least) is the filename excludes the epoch
, which means we'd replace an existing package with a different epoch.
Pkg.to_s(...) will let you name based on metadata.
pkg.output(pkg.to_s(“NAME...EPOCH...”))
On Thu, Aug 8, 2019 at 4:14 AM Ryan Conway notifications@github.com wrote:
Thanks @jordansissel https://github.com/jordansissel yeah that should work too, however we were hoping to generate the format automatically based on the metadata, rather than specifying it statically. The only thing wrong with the default pattern (for .deb at least) is the filename excludes the epoch, which means we'd replace an existing package with a different epoch.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/jordansissel/fpm/issues/1659?email_source=notifications&email_token=AABAF2QAJJO5XLIOSYEFT3TQDP52DA5CNFSM4IKBRJU2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD33JESQ#issuecomment-519475786, or mute the thread https://github.com/notifications/unsubscribe-auth/AABAF2QRTELNEJOVZ34CQK3QDP52DANCNFSM4IKBRJUQ .
Thanks Jordan, I'm going to close this as I think the issue is how exactly to pass this through from FPM Cookery, and I already opened a separate issue there :)
Thanks!
Hi @jordansissel
We've encountered an unusual issue with the Debian Epoch being missing from the resulting .deb filename. Although the Deb package type supports epoch, when the filename is generated via
.to_s()
, it is not included in the default format, which I can see is determined here:https://github.com/jordansissel/fpm/blob/master/lib/fpm/package/deb.rb#L1043-L1047
I can see that this method supports passing in a format, defaulting to:
"NAME_FULLVERSION_ARCH.EXTENSION"
.We'd like to change it to match the Debian packaging spec:
"NAME_EPOCH:FULLVERSION_ARCH.EXTENSION"
.Is it possible to set this via some mechanism, or do we need to monkey patch?
Behind the scenes we're using
fpm-cookery
and monkey patching in the recipe does work, but feels wrong :DThanks for your time :)