Merge pull request #1236 from ajaxorg/mode-updates

Mode updates
This commit is contained in:
Harutyun Amirjanyan 2013-02-07 06:33:15 -08:00
commit 63340911d5
6 changed files with 45 additions and 9 deletions

View file

@ -16,6 +16,12 @@
#include <boost/asio/io_service.hpp> #include <boost/asio/io_service.hpp>
#include "boost/asio/io_service.hpp" #include "boost/asio/io_service.hpp"
#include \
\
"iostream" \
"string" \
<vector>
using namespace std; using namespace std;
int main () int main ()

View file

@ -30,6 +30,8 @@ get_repo() {
fi fi
} }
echo ${#x[@]}
if repo=`get_repo $@`; then if repo=`get_repo $@`; then
branch=`git symbolic-ref HEAD 2>/dev/null` branch=`git symbolic-ref HEAD 2>/dev/null`
echo "http://github.com/$repo/pull/new/${branch##refs/heads/}" echo "http://github.com/$repo/pull/new/${branch##refs/heads/}"

View file

@ -52,6 +52,25 @@
["constant.other"," \"boost/asio/io_service.hpp\""] ["constant.other"," \"boost/asio/io_service.hpp\""]
],[ ],[
"start" "start"
],[
"directive",
["keyword","#include"],
["constant.other.multiline"," \\"]
],[
"directive",
["constant.other.multiline"," \\"]
],[
"directive",
["constant.other.multiline"," \"iostream\" \\"]
],[
"directive",
["constant.other.multiline"," \"string\" \\"]
],[
"start",
["constant.other"," <vector>"]
],[
"start",
["text"," "]
],[ ],[
"start", "start",
["keyword.control","using"], ["keyword.control","using"],

View file

@ -269,6 +269,18 @@
["paren.rparen","}"] ["paren.rparen","}"]
],[ ],[
"start" "start"
],[
"start",
["support.function.builtin","echo"],
["text"," $"],
["paren.lparen","{"],
["text","#"],
["identifier","x"],
["paren.lparen","["],
["text","@"],
["paren.rparen","]}"]
],[
"start"
],[ ],[
"start", "start",
["keyword","if"], ["keyword","if"],

View file

@ -145,6 +145,10 @@ var c_cppHighlightRules = function() {
token : "constant.other.multiline", token : "constant.other.multiline",
regex : /\\/ regex : /\\/
}, },
{
token : "constant.other.multiline",
regex : /.*\\/
},
{ {
token : "constant.other", token : "constant.other",
regex : "\\s*<.+?>", regex : "\\s*<.+?>",
@ -160,10 +164,6 @@ var c_cppHighlightRules = function() {
regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']", regex : "\\s*['](?:(?:\\\\.)|(?:[^'\\\\]))*?[']",
next : "start" next : "start"
}, },
{
token : "constant.other.multiline",
regex : /.*\\/
},
// "\" implies multiline, while "/" implies comment // "\" implies multiline, while "/" implies comment
{ {
token : "constant.other", token : "constant.other",

View file

@ -78,8 +78,8 @@ var ShHighlightRules = function() {
this.$rules = { this.$rules = {
"start" : [ { "start" : [ {
token : "comment", token : ["text", "comment"],
regex : "#.*$" regex : /(^|\s)(#.*)$/
}, { }, {
token : "string", // " string token : "string", // " string
regex : '"(?:[^\\\\]|\\\\.)*?"' regex : '"(?:[^\\\\]|\\\\.)*?"'
@ -116,9 +116,6 @@ var ShHighlightRules = function() {
}, { }, {
token : "paren.rparen", token : "paren.rparen",
regex : "[\\]\\)\\}]" regex : "[\\]\\)\\}]"
}, {
token : "text",
regex : "\\s+"
} ] } ]
}; };
}; };