Is there any way to pass a parameter into dpkg -i that can then be used by preinst and postinst? I've looked into this and was wondering if I could refer to these parameters with $1 or $2
Thanks in advance
No, you cannot pass a parameter that way.
You can set an environmental variable this way
$ VARIABLE=foo dpkg --install package.deb
or (much better) use debconf to ask questions to the user.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With