How to silently install the pkg file on Mac OS X

I am developing a Mac OS X application (cloud printing application). To run my application, I need some support drivers. So I packaged these drivers and my application using the software for creating packages. And I created a pkg file.

It works great as a package installer. But I need to silently install this package by running scripts / commands in the terminal.

PS: Silent install is a method that will install the software with any user intervention (for example, agree to the conditions). he will silently install the software using the admin admin using the terminal commands. On the side of the window, you can make this silent installation.

Can someone provide a solution for this silent installation in the package installer?

+7
macos silent-installer packagemaker
source share
3 answers

Before moving on to other installers, we can easily install the installer package using the following command

sudo installer -store -pkg "/User/MyName/Desktop/helloWorld.pkg" -target / 

Got a link from this link.

+7
source share

you can use the [platypus] or [pkginastall] library

I did not use it myself.

+2
source share

To install the * .pkg file silently, it must have administrator rights. Just run my command below if you have an administrator password: echo "your_admin_pwd" | sudo -S installer -allowUntrusted -verboseR -pkg "path/to/your.pkg" -target / echo "your_admin_pwd" | sudo -S installer -allowUntrusted -verboseR -pkg "path/to/your.pkg" -target /

+2
source share

All Articles