All Projects β†’ scriptingosx β†’ Quickpkg

scriptingosx / Quickpkg

Licence: apache-2.0
wrapper for pkgbuild to quickly build simple packages from an installed app, a dmg or zip archive.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Quickpkg

Desktoppr
Simple command line tool to set the desktop picture on macOS
Stars: ✭ 127 (-7.3%)
Mutual labels:  command-line-tool, macadmin, terminal
Initior
A command line application that let's you initialize your new projects the right way, replaces npm and yarn's init πŸŽ†
Stars: ✭ 17 (-87.59%)
Mutual labels:  command-line-tool, terminal
Qr Filetransfer
Transfer files over WiFi between your computer and your smartphone from the terminal
Stars: ✭ 738 (+438.69%)
Mutual labels:  command-line-tool, terminal
Ed
A modern UNIX ed (line editor) clone written in Go
Stars: ✭ 44 (-67.88%)
Mutual labels:  command-line-tool, terminal
Tsukae
πŸ§‘β€πŸ’»πŸ“Š Show off your most used shell commands
Stars: ✭ 345 (+151.82%)
Mutual labels:  command-line-tool, terminal
Jmxterm
Interactive command line JMX client
Stars: ✭ 389 (+183.94%)
Mutual labels:  command-line-tool, terminal
Sqlite Global Tool
SQLite .NET Core CLI tool that allows the user to manually enter and execute SQL statements with or without showing query result.
Stars: ✭ 37 (-72.99%)
Mutual labels:  command-line-tool, terminal
diskspace
macOS command line tool to return the available disk space on APFS volumes
Stars: ✭ 123 (-10.22%)
Mutual labels:  command-line-tool, macadmin
Mac Zsh Completions
macOS specific additional completion definitions for Zsh.
Stars: ✭ 79 (-42.34%)
Mutual labels:  macadmin, terminal
Sampler
Tool for shell commands execution, visualization and alerting. Configured with a simple YAML file.
Stars: ✭ 9,203 (+6617.52%)
Mutual labels:  command-line-tool, terminal
Tooling
Advancing Node.js as a framework for writing great tools
Stars: ✭ 98 (-28.47%)
Mutual labels:  command-line-tool, terminal
Gitui
Blazing πŸ’₯ fast terminal-ui for git written in rust πŸ¦€
Stars: ✭ 6,762 (+4835.77%)
Mutual labels:  command-line-tool, terminal
Whatsapp Play
Command line software through which you can play with your WhatsApp. It is having different options to play with your WhatsApp like message blast, online tracking, whatsapp chat..
Stars: ✭ 289 (+110.95%)
Mutual labels:  command-line-tool, terminal
Sultan
Sultan: Command and Rule over your Shell
Stars: ✭ 625 (+356.2%)
Mutual labels:  command-line-tool, terminal
Theme.sh
A script which lets you set your $terminal theme.
Stars: ✭ 290 (+111.68%)
Mutual labels:  command-line-tool, terminal
Google Images Download
Python Script to download hundreds of images from 'Google Images'. It is a ready-to-run code!
Stars: ✭ 7,815 (+5604.38%)
Mutual labels:  command-line-tool, terminal
Termchat
Terminal chat through the LAN.
Stars: ✭ 229 (+67.15%)
Mutual labels:  command-line-tool, terminal
Covid19 Tracker Cli
A curl-based command line tracker for Novel Coronavirus or COVID-19 pandemic. It Supports terminal for linux and macos, command prompt for windows, and termux for android with real-time updates.
Stars: ✭ 244 (+78.1%)
Mutual labels:  command-line-tool, terminal
Mocha Chrome
β˜•οΈ Run Mocha tests using headless Google Chrome
Stars: ✭ 66 (-51.82%)
Mutual labels:  command-line-tool, terminal
Typin
Declarative framework for interactive CLI applications
Stars: ✭ 126 (-8.03%)
Mutual labels:  command-line-tool, terminal

quickpkg - Build packages quickly

This tool will quickly and easily build a package from an installed application, a disk image file or zip archive with an enclosed application bundle. It will also extract the application name and version and use it to name the resulting pkg file.

The tool will look for applications on the first level of the disk image or archive. If it finds no or more than one application it will error.

The name of the resulting package will be of the form {name}-{version}.pkg. Spaces will be removed from the name. The package will be written to the current working directory.

Examples

Build package from installed application:

quickpkg /Applications/Numbers.app

Build package from a disk image:

quickpkg ~/Downloads/Firefox\ 43.0.4.dmg

Build package from a zip archive:

quickpkg ~/Downloads/Things.zip

Options

--scripts scripts_folder:

Pass a folder with scripts that are passed to pkgbuild's --scripts option. If the there is a preinstall and/or postinstall script they will be run at the respective and can call other scripts in this folder.

--postinstall postinstall_script

Use the script file given as a postinstall script. If given together with the -scripts option will attempt to merge the two and error if a postinstall script is already present.

--preinstall preinstall_script

Use the script file given as a preinstall script. If given together with the -scripts option will attempt to merge the two and error if a preinstall script is already present.

--ownership {recommended,preserve,preserve-other}

This parameter will be passed into pkgbuild. Default is recommended. See man pkgbuild for details.

--output pkgpath

Will write the resulting package to pkgpath instead of the current working directory. If pkgpath is a directory, then the default package name ({name}-{version}.pkg) is used. You can also give the complete path, including a name. You can use the placeholders {name}, {version} and {identifier} in the name.

Examples:

quickpkg /Applications/Numbers.app --output ~/Packages/

Will create Numbers-X.Y.Z.pkg in ~/Packages.

quickpkg /Applications/Numbers.app --output Numbers_latest.pkg

will create Numbers_latest.pkg in the current working directory.

quickpkg /Applications/Numbers.app --output ~/Packages/{identifier}_{version}.pkg

will create com.apple.Numbers_X.Y.Z.pkg in ~/Packages.

--[no-]relocatable

Controls wether the resulting pkg file is relocatable, i.e. if the installer process will search for the bundle by bundle-identifier if it was moved to another location. By default packages will be created NON-relocatable.

--sign, --keychain and --cert

You can add these options to sign the resulting package. These three options are passed through to the pkgbuild command. Read the pkgbuild man page for details.

Usually you can find the proper signing identity (from the Apple Developer account) with the command

$ security find-identity -p basic -v

and then you add the proper identity with the --sign option.

$ quickpkg ~/Downloads/Firefox\ 53.0.3.dmg --sign "3rd Party Mac Developer Installer: Your Name Here"

Background

OS X has had the pkgbuild tool since Xcode 3.2 on Snow Leopard. With pkgbuild you can directly build a installer package from an application in the /Applications folder:

pkgbuild --component /Applications/Numbers.app Numbers.pkg

Or even an application inside a mounted dmg:

pkgbuild --component /Volumes/Firefox/Firefox.app \
         --install-location /Applications \
         Firefox.pkg

This tool even does the work of determining a bundle's identifier and version and sets the identifier and version of the pkg to the same values.

However, while pkgbuild does automatically name the package, it does not include the version, which is important when you tracking many versions of the same application. It also doesn't automatically look into a dmg file or zip archive.

quickpkg vs autopkg

This tool is not meant to replace autopkg. autopkg will automate the download, the re-packaging (if necessary) and the upload to and configuration of your client management system. It can also handle much more complex setups than quickpkg. autopkg is far superior and should be your tool of choice.

However, there are situations where autopkg does not work well. The most common reason is if the download cannot be automated because the download page is behind a paywall. Or maybe you are just experimenting with a test server and do not want to change your production autopkg setup. Also autopkg requires a recipe for a given piece of software. If no recipe exists, quickpkg may be a simple alternative. (Though if quickpkg works, creating an autopkg recipe should not be hard.)

quickpkg vs munkipkg

quickpkg is meant for 'quick' packaging. No configuration, no options. Download the application from the AppStore or the dmg or zip from the web and go. (I started working on it because I could never remember the exact options needed for pkgbuild.) munkipkg is a tool that makes it easier to access the complex options of pkgbuild and packagebuild, but it still supports complex projects.

If you prefer a UI rather than a command line tool, then use StΓ©phane Sudre's Packages.

Warning

All quickpkg does is identify an application bundle and package it in a way that the package will install that application bundle into the /Applications folder. If the application needs other files (libraries, frameworks, configuration files, license files, preferences etc.) to run and work they are your responsibility.

Also be sure to understand what you are running quickpkg against. If you run quickpkg on the disk image you get from DropBox or for the Adobe Flash Player, you will get a pkg that installs the DropBox or Flash Player installer in the /Applications folder. Probably not what you wanted.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].