Table of Contents

Appify shell script creates macOS app bundle from the script. It works on all major macOS X versions on PowerPC, Intel or ARM architectures.

Script

#!/usr/bin/env bash

APPNAME=${2:-$(basename "${1}" '.sh')};
DIR="${APPNAME}.app/Contents/MacOS";

if [ -a "${APPNAME}.app" ]; then
	echo "${PWD}/${APPNAME}.app already exists :(";
	exit 1;
fi;

mkdir -p "${DIR}";
cp "${1}" "${DIR}/${APPNAME}";
chmod +x "${DIR}/${APPNAME}";

echo "${PWD}/$APPNAME.app";

Copy it to the /usr/local/bin/appify and chmod +x /usr/local/bin/appify

Usage

appify <shell script.sh> <app bundle name>

Change icon

You can easily change app bundle icon following this guide and find icons here.

 
appify.txt · Last modified: 2022-03-13 19:53 by e1z0
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial 4.0 International
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki