Something went wrong. Try again.
Monorepo for Aesthetic.Computer aesthetic.computer
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536#!/bin/bash# frame — node-resolving wrapper around frame.mjs (mirrors the asana wrapper).## Symlinked into ~/.local/bin like the other slab bins; resolves through the# symlink so SCRIPT points at frame.mjs next to this wrapper, then finds a# usable node even under launchd's minimal PATH.set -uSRC="${BASH_SOURCE[0]}"while [ -L "$SRC" ]; do DIR="$(cd -P "$(dirname "$SRC")" && pwd)" SRC="$(readlink "$SRC")" [[ "$SRC" != /* ]] && SRC="$DIR/$SRC"doneHERE="$(cd -P "$(dirname "$SRC")" && pwd)"SCRIPT="$HERE/frame.mjs"find_node() { if command -v node >/dev/null 2>&1; then command -v node; return; fi local c for c in \ "$HOME/.local/share/fnm/aliases/default/bin/node" \ "$HOME/.fnm/aliases/default/bin/node" \ /opt/homebrew/bin/node \ /usr/local/bin/node \ "$HOME/.volta/bin/node"; do [ -x "$c" ] && { echo "$c"; return; } done c=$(ls -td "$HOME"/.local/share/fnm/node-versions/*/installation/bin/node \ 2>/dev/null | head -1) [ -n "$c" ] && [ -x "$c" ] && { echo "$c"; return; } return 1}NODE="$(find_node)" || { echo "frame: no node found" >&2; exit 1; }exec "$NODE" "$SCRIPT" "$@"