Animated app icons in your Dock that can run an arbitrary shell script when clicked.

Overview

Live App Icon for Mac

Animated app icons in your Dock that can run an arbitrary shell script when clicked.

Requirements

  • macOS 13 (Ventura) or higher
  • Xcode (or at least xcodebuild) version 14.1 or higher
  • Apple Development Certificate (Personal Team ID)
  • Not too old git

If you have the latest version of Xcode, the above requirements should be met.

Install laic

laic (Live App Icon Creator) is a simple CLI tool to generate Live App Icons on macOS. There are 2 ways to install laic: using cargo from Rust or download a binary.

Use cargo

If you are a Rust developer, the easiest way to install laic is with cargo, since it is published on crate.io.

cargo install laic

Download a binary

There are pre-compiled binraies in the release page. You can manually download and install it in an appropriate location (e.g. /usr/local/bin). Select laic-aarch64-apple-darwin if you are using Apple Silicon Mac, or laic-x86_64-apple-darwin if Intel Mac.

The following one line command will automatically download and install laic to /usr/local/bin on Apple Silicon Mac:

curl -L -o laic https://github.com/fujidaiti/live-app-icon/releases/download/v0.1.0/laic-aarch64-apple-darwin && chmod +x ./laic && sudo mv ./laic /usr/local/bin

Or on Intel Mac:

curl -L -o laic https://github.com/fujidaiti/live-app-icon/releases/download/v0.1.0/laic-x86_64-apple-darwin && chmod +x ./laic && sudo mv ./laic /usr/local/bin

Usage

laic requires at least 3 arguments:

  • --name : Name of the app to be generated. Used as its display name in the dock and app launcher.
  • --gif : Path to an animated GIF to be used as the icon of the app. If the width and height of the image are not equal, the image will be resized to a square according to the specified resize method.
  • --command : Shell command to be executed when the generated app is clicked.

The below is an example to generate an animated app icon that is named as "GitHub" that, when clicked, opens the home page of GitHub in your default browser.

laic --name "GitHub" --gif path/to/your/gif --command "open https://github.com"

There are other options that laic accepts:

  • --resize-method : Specifies how the given GIF will be resized to a square. See Resize method for more details.

  • --install-location : Path to a directory the app to be installed. The default is $HOME/Applications.

  • --install-action : Specify the action to be taken when the app is successfully installed. launch launches the app immediately, open-in-finder opens the directory where the app is installed in the Finder, and none does nothing. The default is launch.

  • --verbose : Noisy logging, including all shell commands executed.

Run laic --help for more information.

Resize methods

If the width and height of the given animated GIF are not equal, laic resizes it to a square according to a given resize method:

  • center-crop : Crops the center of the image with a square whose sides are the same size as the shorter side of the image.
  • center-fit : Puts the image on the center of a transparent square whose sides are the same size as the longer side of the image.

The default method is center-fit.

After installation is finished

Keep the app in Dock

It is recommended enabling the "Keep in Dock" option for the app so that the nice animation always catches your eye 👀 .

keep-in-dock

Login Items

When the generated app launchs for the first time, it automatically adds itself to Login Items. This is because the animation of the app icon is only available while the app is running. You might notice that if you quit the app, the animation also stops.

add-to-login-items

Allow notifications

In addition, the app will also require the permission to send notifications at the first launch. It will notify you in a notificaation if an error occurs while running the command.

notification-request

Integrate with Shortcuts

Since the generated app can run arbitrary shell commands, it is easy to perform complex workflows created with Shortcuts. Did you know that we can also run the shortcuts from the command line? For example, to run a shortcut named "My Shortcut", you could use the following:

shortcuts run "My Shortcut"

Then it is easy to integrate this shortcut with App Live Icon as follows:

laic --label "My Shortcut" --command "shortcuts run \"My Shortcut\"" --gif path/to/your/gif

Notice that you need to escape the doube quotes in --command part since the shortcut name contains a whitespace. You can read Run shortcuts from the command line for more information about shortcuts command.

Uninstall

Cargo

If you have installed laic with cargo install laic, just run cargo uninstall laic.

Binaries

If you have manually installed a laic executable, you can remove it like sudo rm /usr/local/bin/laic , or move it to the Trash by hand.

Generated apps

Just move it to the Trash. The default install location is $HOME/Applications unless you specify a specific directory at creation. You may also need to remove the app from Login Items and the Notifications section in the System Setting.

Troubleshooting

If you try to run the laic you downloaded, you might see a warning dialog like the one in the image below. This is because the binary is not signed by the identified developer. In this case, you must manually allow the app to run according to this article: Open Mac app from unidentified developer.

warning-dialog

Thanks

joe-dart

Contributing

If you find any bugs or have suggestions for improvement, please create an issue or a pull request on the GitHub repository. Contributions are welcome and appreciated!

TODO

Animated icons

  • Add option to notify the command outputs
  • Allow more complex animations (e.g. attention concepts)

CLI tool

  • Validate the arguments
  • Refactor the code
  • Improve the report messages
  • Add tests
  • Check the requirements before run

Others

  • Create a GUI icon generator
  • Provide a way to create animated icons without Xcode
You might also like...
🐢 Atuin replaces your existing shell history with a SQLite database, and records additional context for your commands
🐢 Atuin replaces your existing shell history with a SQLite database, and records additional context for your commands

Atuin replaces your existing shell history with a SQLite database, and records additional context for your commands. Additionally, it provides optional and fully encrypted synchronisation of your history between machines, via an Atuin server.

Traversal of tree-sitter Trees and any arbitrary tree with a TreeCursor-like interface

tree-sitter-traversal Traversal of tree-sitter Trees and any arbitrary tree with a TreeCursor-like interface. Using cursors, iteration over the tree c

Abuse the node.js inspector mechanism in order to force any node.js/electron/v8 based process to execute arbitrary javascript code.
Abuse the node.js inspector mechanism in order to force any node.js/electron/v8 based process to execute arbitrary javascript code.

jscythe abuses the node.js inspector mechanism in order to force any node.js/electron/v8 based process to execute arbitrary javascript code, even if t

A PoC for the CVE-2022-44268 - ImageMagick arbitrary file read
A PoC for the CVE-2022-44268 - ImageMagick arbitrary file read

CVE-2022-44268 Arbitrary File Read PoC - PNG generator This is a proof of concept of the ImageMagick bug discovered by https://www.metabaseq.com/image

AI-TOML Workflow Specification (aiTWS), a comprehensive and flexible specification for defining arbitrary Ai centric workflows.

AI-TOML Workflow Specification (aiTWS) The AI-TOML Workflow Specification (aiTWS) is a flexible and extensible specification for defining arbitrary wo

Blazingly fast interpolated LUT generator and applicator for arbitrary and popular color palettes.
Blazingly fast interpolated LUT generator and applicator for arbitrary and popular color palettes.

lutgen-rs A blazingly fast interpolated LUT generator and applicator for arbitrary and popular color palettes. Theme any image to your dekstop colorsc

Encode and decode dynamically constructed values of arbitrary shapes to/from SCALE bytes

scale-value · This crate provides a Value type, which is a runtime representation that is compatible with scale_info::TypeDef. It somewhat analogous t

A library that allows for the arbitrary inspection and manipulation of the memory and code of a process on a Linux system.
A library that allows for the arbitrary inspection and manipulation of the memory and code of a process on a Linux system.

raminspect raminspect is a crate that allows for the inspection and manipulation of the memory and code of a running process on a Linux system. It pro

Shell scripting that will knock your socks off
Shell scripting that will knock your socks off

atom Shell scripting that will knock your socks off. NOTE: Click the image above for a video demonstration.

Releases(v0.1.0)
🔣 nerdfix helps you to find/fix obsolete Nerd Font icons in your project.

?? nerdfix nerdfix helps you to find/fix obsolete Nerd Font icons in your project. ?? Why Nerd Fonts is used in many projects for a beautiful UI. It p

Loi Chyan 80 Apr 8, 2023
CLI for video images. Generates animated video contact sheets fast.

vimg CLI for video images. Generate animated video contact sheets fast. Uses ffmpeg. Note: Support for animated avif isn't everywhere yet, try viewing

Alex Butler 4 Mar 12, 2023
A Rust-based shell script to create a folder structure to use for a single class every semester. Mostly an excuse to use Rust.

A Rust Course Folder Shell Script PROJECT IN PROGRESS (Spring 2022) When completed, script will create a folder structure of the following schema: [ro

Sebastián Romero Cruz 1 Apr 10, 2022
a universal meta-transliterator that can decipher arbitrary encoding schemas, built in pure Rust

transliterati a universal meta-transliterator that can decipher arbitrary encoding schemas, built in pure Rust what does it do? You give it this: Барл

Catherine Koshka 7 Dec 21, 2022
🧬 Material Icons for Dioxus

?? Dioxus Material Icons This project provides a simple but configurable component to render Google's Material Icons in Dioxus. ?? How to get started

Lennart Kloock 6 Jan 31, 2023
12600+ icons pack for embedded graphics!

?? embedded-icon 12600+ ?? icons for embedded-graphics. ?? Features ?? Support to multiple icon packs - Easy to add support to! ?? Multiple resolution

Patrick José Pereira 3 Jul 24, 2023
Replace an app's icon from a png with a single terminal script. Made with Rust

Replace macOS App Icon Replace an app's icon from a png with a single terminal CLI. Made with Rust

Kunal Bagaria 8 Aug 3, 2022
belt is a command line app that can show your time from a list of selected time zones

A CLI app to show your time from a list of selected time zones, and a rust lib to parse dates in string formats that are commonly used.

Rollie Ma 23 Nov 4, 2022
zigfi is an open-source stocks, commodities and cryptocurrencies price monitoring CLI app, written fully in Rust, where you can organize assets you're watching easily into watchlists for easy access on your terminal.

zigfi zigfi is an open-source stocks, commodities and cryptocurrencies price monitoring CLI app, written fully in Rust, where you can organize assets

Aldrin Zigmund Cortez Velasco 18 Oct 24, 2022
A todo list app that indexes your app to find TODO:'s

forgot A todo list app that indexes your app to find TODO:'s Usage to list all your todos forgot list list all your todos ignoring search in ./target,

null 2 Oct 6, 2022