I want to do my installation of pkg file as silent install from mac terminal. So i used the below command to do silent install.
sudo installer -store -pkg "/User/MyName/Desktop/helloWorld.pkg" -target /
It perfectly installed my application. But i want to pass arguments from this command line script to package installer that was created in package maker. So that i can able to use this argument value in post/pre installation script inside the package installer.
Is there any possibility to pass my value as argument in the above command?
Select the Packages payload and click Configure. Click Add for the macOS installer package file. Choose “Cache” from the Action pop-up menu. Specify a distribution point for computers to download the package from.
Save as a package file: Click anywhere in the document window to make it active, then choose File > Advanced > Change File Type > Package (from the File menu at the top of your screen).
This is not possible from the command since the "installer
" command does not support any such arguments. However, you may try using a configuration file which you can read from pre/postinstall script and do the required actions.
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