Skip to content

Commit

Permalink
Merge pull request #4 from snomos/master
Browse files Browse the repository at this point in the history
Makefile.seemode
  • Loading branch information
m4p committed Jul 5, 2016
2 parents db12948 + 290964c commit f1e76dc
Show file tree
Hide file tree
Showing 10 changed files with 164 additions and 0 deletions.
22 changes: 22 additions & 0 deletions Modes/Makefile.seemode/Contents/Info.plist
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSHumanReadableCopyright</key>
<string>2.0, © Scott dunlop 2004, SEE 4 version © divvun@uit.no</string>
<key>CFBundleIdentifier</key>
<string>SEEMode.Makefile</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Makefile</string>
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>2.0</string>
<key>CFBundleVersion</key>
<string>2.0</string>
<key>SEEMinimumEngineVersion</key>
<string>4.0</string>
</dict>
</plist>
Empty file.
Binary file not shown.
10 changes: 10 additions & 0 deletions Modes/Makefile.seemode/Contents/Resources/ModeSettings.xml
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE syntax SYSTEM "settings.dtd">
<settings>
<recognition>
<filename>Makefile</filename>
<filename>makefile</filename>
<filename>GNUmakefile</filename>
<filename>Makefile.am</filename>
</recognition>
</settings>
7 changes: 7 additions & 0 deletions Modes/Makefile.seemode/Contents/Resources/RegexSymbols.xml
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE syntax SYSTEM "symbol.dtd">
<symbols>
<symbol id="Makefile Rule" image="SymbolM" indentation="0">
<regex>(^[^\n\r\s#]*):</regex>
</symbol>
</symbols>
28 changes: 28 additions & 0 deletions Modes/Makefile.seemode/Contents/Resources/Scripts/RunMake.scpt
@@ -0,0 +1,28 @@
--$Id: RunMake.applescript,v 1.1 2007/07/08 19:58:26 mjb Exp $

tell application "SubEthaEdit"
if exists file of front document then
if modified of front document then
try
save front document
end try
end if
set MacfrontFilePath to file of front document
set frontFilePath to POSIX path of MacfrontFilePath
set modeResources to resource path of mode of front document
else
error "You have to save the document first"
end if
end tell

set shellScript to quote & modeResources & "/Scripts/shell/runmake.sh" & quote & space & quote & frontFilePath & quote

-- debug: display alert "Make command" message shellScript as informational buttons {"OK"} default button "OK"

set makeResponse to do shell script shellScript

display alert "Make Response" message makeResponse as informational buttons {"OK"} default button "OK"

on seescriptsettings()
return {displayName:"Run make", keyboardShortcut:"@b", inContextMenu:"no"}
end seescriptsettings
@@ -0,0 +1,5 @@
#!/bin/sh

#$Id: runmake.sh,v 1.2 2007/07/10 08:45:42 mjb Exp $

make -C "$(dirname \"$1\")" -f "$1"
91 changes: 91 additions & 0 deletions Modes/Makefile.seemode/Contents/Resources/SyntaxDefinition.xml
@@ -0,0 +1,91 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE syntax SYSTEM "syntax.dtd">

<syntax>
<head>
<name>Makefile Syntax</name>
<charsintokens><![CDATA[_0987654321abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ@-.]]></charsintokens>
<!-- <charsdelimitingtokens>[CDATA[ -]]></charsdelimitingtokens> -->
</head>
<states>
<default id="Base" scope="meta.default">
<keywords id="Keywords" casesensitive="yes" useforautocomplete="yes" scope="keyword">
<string>ifdef</string>
<string>ifndef</string>
<string>ifeq</string>
<string>ifneq</string>
<string>define</string>
<string>else</string>
<string>endif</string>
<string>include</string>
<string>sinclude</string>
<string>-include</string>
<string>override</string>
<string>endef</string>
<string>unexport</string>
<string>vpath</string>
<string>subst</string>
<string>patsubst</string>
<string>strip</string>
<string>filter</string>
<string>sort</string>
<string>dir</string>
<string>notdir</string>
<string>suffix</string>
<string>basename</string>
<string>addsuffix</string>
<string>addprefix</string>
<string>join</string>
<string>word</string>
<string>words</string>
<string>wordlist</string>
<string>firstword</string>
<string>wildcard</string>
<string>error</string>
<string>warning</string>
<string>shell</string>
<string>origin</string>
<string>foreach</string>
<string>call</string>
<string>MAKEFILES</string>
<string>VPATH</string>
<string>SHELL</string>
<string>MAKESHELL</string>
<string>MAKE</string>
<string>MAKELEVEL</string>
<string>MAKEFLAGS</string>
<string>MAKECMDGOALS</string>
<string>CURDIR</string>
<string>SUFFIXES</string>
<string>.LIBPATTERNS</string>
</keywords>
<state id="SingleComment" scope="comment.line">
<begin>
<regex>#</regex>
</begin>
<end>
<regex>.(?=[\n\r])</regex>
</end>
</state>
<state id="String" scope="string.double">
<begin>
<regex>"</regex>
</begin>
<end>
<regex>(((?&lt;!\\)(\\\\)*)|^)"</regex>
</end>
</state>
<state id="Command" type="block" foldable="yes" scope="language.subroutine.method">
<begin>
<regex>(?:^\t)</regex>
</begin>
<end>
<regex>[\n\r](?=[^\t])</regex>
</end>
<import keywords-only="yes"/>
<state-link state="SingleComment"/>
<state-link state="String"/>
</state>
</default>
</states>
</syntax>
1 change: 1 addition & 0 deletions Modes/README.md
Expand Up @@ -5,6 +5,7 @@ Language | Version | Update Date | Comment | Author
---------|---------|-------------|---------|----------
c# ([zip](../../../raw/master/Modes/zipped/C%23.seemode.zip)) | 2.0 | 2014-06-18 | Quick simple C# mode | [m4p](https://github.com/m4p)
Dtrace ([zip](../../../raw/master/Modes/zipped/Dtrace.seemode.zip)) | 1.0.1 | 2014-06-24 | Mode for DTrace scripts | [tbartelmess](https://github.com/tbartelmess)
Makefile ([zip](../../../raw/master/Modes/zipped/Makefile.seemode.zip)) | 2.0 | 2016-06-28 | Mode for Makefile's | [snomos](https://github.com/snomos)
SQL ([zip](../../../raw/master/Modes/zipped/SQL.seemode.zip)) | 4.0 | 2014-07-09 | SQL Mode - ported from built-in SEE 3 Mode | [ellduin](https://github.com/ellduin)
Swift ([zip](../../../raw/master/Modes/zipped/Swift.seemode.zip)) | 1.0 | 2014-06-21 | Swift Mode - also contains swiftc.sh to write command line tools with full argument and cocoa support | [monkeydom](https://github.com/monkeydom)
Thrift ([zip](../../../raw/master/Modes/zipped/Thrift.seemode.zip)) | 1.0 | 2014-06-22 | Mode for Apache thrift | [tbartelmess](https://github.com/tbartelmess)
Expand Down
Binary file added Modes/zipped/Makefile.seemode.zip
Binary file not shown.

0 comments on commit f1e76dc

Please sign in to comment.