From c0aa4c45f5d8bba45dd4266637a426accfcdd6d3 Mon Sep 17 00:00:00 2001 From: Derek Stevens Date: Wed, 11 Aug 2021 16:05:12 -0600 Subject: [PATCH] update micro configs, add uxntal syntax hilighting --- micro/bindings.json | 8 ++++++++ micro/{ => colorschemes}/solarwolf.micro | 0 micro/{ => colorschemes}/solarwolf_fb.micro | 0 micro/syntax/uxn.yaml | 11 +++++++++++ 4 files changed, 19 insertions(+) create mode 100644 micro/bindings.json rename micro/{ => colorschemes}/solarwolf.micro (100%) rename micro/{ => colorschemes}/solarwolf_fb.micro (100%) create mode 100644 micro/syntax/uxn.yaml diff --git a/micro/bindings.json b/micro/bindings.json new file mode 100644 index 0000000..1ebec2c --- /dev/null +++ b/micro/bindings.json @@ -0,0 +1,8 @@ +{ + "Alt-/": "lua:comment.comment", + "Alt-a": "lua:snippets.Accept", + "Alt-d": "lua:snippets.Cancel", + "Alt-s": "lua:snippets.Insert", + "Alt-w": "lua:snippets.Next", + "CtrlUnderscore": "lua:comment.comment" +} diff --git a/micro/solarwolf.micro b/micro/colorschemes/solarwolf.micro similarity index 100% rename from micro/solarwolf.micro rename to micro/colorschemes/solarwolf.micro diff --git a/micro/solarwolf_fb.micro b/micro/colorschemes/solarwolf_fb.micro similarity index 100% rename from micro/solarwolf_fb.micro rename to micro/colorschemes/solarwolf_fb.micro diff --git a/micro/syntax/uxn.yaml b/micro/syntax/uxn.yaml new file mode 100644 index 0000000..f8f8cc2 --- /dev/null +++ b/micro/syntax/uxn.yaml @@ -0,0 +1,11 @@ +filetype: uxntal + +detect: + filename: "\\.tal$" + +rules: + - constant: "[\"#'|$][^\ \n\r]+" + - identifier: "[@,;.&][^\ \n\r]+" + - statement: "\\b(BRK|LIT|NOP|POP|DUP|SWP|OVR|ROT|EQU|NEQ|GTH|LTH|JMP|JCN|JSR|STH|LDZ|STZ|LDR|STR|LDA|STA|DEI|DEO|ADD|SUB|MUL|DIV|AND|ORA|EOR|SFT)[2rk]?\\b" + - comment: "\\([\\S\\s]*\\)" + - symbol: "\\[|\\]"