1 ! File: aquamacs.factor
4 ! Description: Another fine Factor file!
5 ! Copyright (C) 2017 Dave Carlton.
6 ! See http://factorcode.org/license.txt for BSD license.
7 USING: editors io.pathnames io.standard-paths kernel make
8 math.parser namespaces sequences system ;
13 editor-class [ aquamacs ] initialize
15 HOOK: find-aquamacs-path os ( -- path )
17 M: object find-aquamacs-path f ;
19 M: macosx find-aquamacs-path
20 "org.gnu.Aquamacs" find-native-bundle [
21 "Contents/MacOS/bin/aquamacs" append-path
26 : aquamacs-path ( -- path )
28 find-aquamacs-path [ "aquamacs" ?find-in-path ] unless*
31 M: aquamacs editor-command ( file line -- command )
32 [ aquamacs-path , drop , ] { } make ;