1 ! Copyright (C) 2004, 2010 Slava Pestov.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: combinators.short-circuit editors io.pathnames
4 io.standard-paths kernel make math.parser namespaces sequences
9 jedit editor-class set-global
11 HOOK: find-jedit-path os ( -- path )
13 M: object find-jedit-path f ;
15 M: macosx find-jedit-path
16 "org.gjt.sp.jedit" find-native-bundle [
17 "Contents/MacOS/jedit" append-path
22 M: windows find-jedit-path
23 { "jedit" } "jedit.exe" find-in-applications ;
25 : jedit-path ( -- path )
27 find-jedit-path [ "jedit" ?find-in-path ] unless*
30 M: jedit editor-command ( file line -- command/f )
34 [ , ] [ number>string "+line:" prepend , ] bi*