From ff28dadf4aee94fbe045a406ceaf0716d6f924fa Mon Sep 17 00:00:00 2001 From: Chase Adams Date: Mon, 20 Apr 2020 22:53:10 -0700 Subject: [PATCH 1/6] add initial asciidoc tokens --- demo/asciidoc.adoc | 14 +++++++++ src/generate-theme.js | 7 +++-- src/token-colors/asciidoc.js | 61 ++++++++++++++++++++++++++++++++++++ 3 files changed, 79 insertions(+), 3 deletions(-) create mode 100644 demo/asciidoc.adoc create mode 100644 src/token-colors/asciidoc.js diff --git a/demo/asciidoc.adoc b/demo/asciidoc.adoc new file mode 100644 index 0000000..a2b636a --- /dev/null +++ b/demo/asciidoc.adoc @@ -0,0 +1,14 @@ += Neon Night: level-0 title + +== level-1 title +This is some *bold* text. +This is _italic_ text. +This is a `monospace` text. + +=== level-2 title + +[source,shell] +---- + GPG_TTY=$(tty) + export GPG_TTY +---- diff --git a/src/generate-theme.js b/src/generate-theme.js index fd03f4e..38fc995 100644 --- a/src/generate-theme.js +++ b/src/generate-theme.js @@ -36,10 +36,11 @@ const generateTheme = ( ...require(`./colors/integrated-terminal`)(palette), ...require(`./colors/debug`)(palette), ...require(`./colors/git`)(palette), - ...require(`./colors/breadcrumbs`)(palette) + ...require(`./colors/breadcrumbs`)(palette), }, tokenColors: [ ...require(`./token-colors/base`)(palette, fontStyleEnabled), + ...require(`./token-colors/asciidoc`)(palette, fontStyleEnabled), ...require(`./token-colors/clojure`)(palette, fontStyleEnabled), ...require(`./token-colors/css`)(palette, fontStyleEnabled), ...require(`./token-colors/docker`)(palette, fontStyleEnabled), @@ -49,8 +50,8 @@ const generateTheme = ( ...require(`./token-colors/json`)(palette, fontStyleEnabled), ...require(`./token-colors/makefile`)(palette), ...require(`./token-colors/markdown`)(palette, fontStyleEnabled), - ...require(`./token-colors/yaml`)(palette) - ] + ...require(`./token-colors/yaml`)(palette), + ], }); module.exports = generateTheme; diff --git a/src/token-colors/asciidoc.js b/src/token-colors/asciidoc.js new file mode 100644 index 0000000..086e1d1 --- /dev/null +++ b/src/token-colors/asciidoc.js @@ -0,0 +1,61 @@ +// @flow + +/* :: +import type {Palette, FontStyles} from '../types' +*/ + +const asciidoc = ( + palette /*: Palette */, + fontStyleEnabled /*: FontStyles */ +) => [ + { + name: `AsciiDoc - Heading 0-6`, + scope: [ + `markup.heading.heading-0.asciidoc`, + `markup.heading.heading-1.asciidoc`, + `markup.heading.heading-2.asciidoc`, + `markup.heading.heading-3.asciidoc`, + `markup.heading.heading-4.asciidoc`, + `markup.heading.heading-5.asciidoc`, + `markup.heading.heading-6.asciidoc`, + ], + settings: { + foreground: palette.magenta, + }, + }, + { + name: `AsciiDoc - Fenced Bode Block`, + scope: [ + `text.asciidoc markup.code markup.heading`, + `text.asciidoc markup.code markup.heading entity.name.function`, + ], + settings: { + foreground: palette.blue, + }, + }, + { + name: `AsciiDoc - Bold`, + scope: [`markup.bold.asciidoc`], + settings: { + fontStyle: `bold`, + }, + }, + { + name: `AsciiDoc - Italic`, + scope: [`markup.italic.asciidoc`], + settings: { + fontStyle: `italic`, + }, + }, + + { + name: `AsciiDoc - Italic`, + scope: [`markup.raw.monospace.asciidoc`], + settings: { + fontStyle: `bold`, + foreground: palette.blue, + }, + }, +]; + +module.exports = asciidoc; From 14519f82855c06548730ba0c70b79e3dfc81f8ba Mon Sep 17 00:00:00 2001 From: Chase Adams Date: Wed, 22 Apr 2020 08:20:42 -0700 Subject: [PATCH 2/6] fix gh actions --- .github/actions/check/action.yaml | 4 ++-- .github/actions/publish/action.yaml | 4 ++-- .github/actions/release/action.yaml | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/actions/check/action.yaml b/.github/actions/check/action.yaml index 6854835..b62c354 100644 --- a/.github/actions/check/action.yaml +++ b/.github/actions/check/action.yaml @@ -1,6 +1,6 @@ name: "Check" description: "Checks code" -runs: +runs: using: "docker" image: "Dockerfile" - entrypiont: "./entrypoint.sh" + entrypoint: "./entrypoint.sh" diff --git a/.github/actions/publish/action.yaml b/.github/actions/publish/action.yaml index cade3ab..9bf14f4 100644 --- a/.github/actions/publish/action.yaml +++ b/.github/actions/publish/action.yaml @@ -1,6 +1,6 @@ name: "Publish to VSCE" description: "Checks code" -runs: +runs: using: "docker" image: "Dockerfile" - entrypiont: "./entrypoint.sh" + entrypoint: "./entrypoint.sh" diff --git a/.github/actions/release/action.yaml b/.github/actions/release/action.yaml index 208b46c..2d180ed 100644 --- a/.github/actions/release/action.yaml +++ b/.github/actions/release/action.yaml @@ -1,6 +1,6 @@ name: "Create Release" description: "Create Release" -runs: +runs: using: "docker" image: "Dockerfile" - entrypiont: "./entrypoint.sh" \ No newline at end of file + entrypoint: "./entrypoint.sh" From 6f9816821977a011b24d982d079017ac9db664ff Mon Sep 17 00:00:00 2001 From: Chase Adams Date: Thu, 23 Apr 2020 20:56:11 -0700 Subject: [PATCH 3/6] rm entrypoints --- .github/actions/check/entrypoint.sh | 3 --- .github/actions/publish/entrypoint.sh | 4 ---- .github/actions/release/entrypoint.sh | 3 --- 3 files changed, 10 deletions(-) delete mode 100755 .github/actions/check/entrypoint.sh delete mode 100755 .github/actions/publish/entrypoint.sh delete mode 100755 .github/actions/release/entrypoint.sh diff --git a/.github/actions/check/entrypoint.sh b/.github/actions/check/entrypoint.sh deleted file mode 100755 index 8104643..0000000 --- a/.github/actions/check/entrypoint.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -set -e -yarn install && yarn test:check-code diff --git a/.github/actions/publish/entrypoint.sh b/.github/actions/publish/entrypoint.sh deleted file mode 100755 index 9a37343..0000000 --- a/.github/actions/publish/entrypoint.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/sh -yarn install \ - && yarn prepublish \ - && yarn vscode:publish diff --git a/.github/actions/release/entrypoint.sh b/.github/actions/release/entrypoint.sh deleted file mode 100755 index 6191ac3..0000000 --- a/.github/actions/release/entrypoint.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh -yarn install \ - && yarn run release From c610f042cade5d5852654fd01b88980ef8679563 Mon Sep 17 00:00:00 2001 From: Chase Adams Date: Thu, 23 Apr 2020 20:58:15 -0700 Subject: [PATCH 4/6] add entrypoints back --- .github/actions/check/entrypoint.sh | 3 +++ .github/actions/publish/entrypoint.sh | 4 ++++ .github/actions/release/entrypoint.sh | 3 +++ 3 files changed, 10 insertions(+) create mode 100755 .github/actions/check/entrypoint.sh create mode 100755 .github/actions/publish/entrypoint.sh create mode 100755 .github/actions/release/entrypoint.sh diff --git a/.github/actions/check/entrypoint.sh b/.github/actions/check/entrypoint.sh new file mode 100755 index 0000000..8104643 --- /dev/null +++ b/.github/actions/check/entrypoint.sh @@ -0,0 +1,3 @@ +#!/bin/sh +set -e +yarn install && yarn test:check-code diff --git a/.github/actions/publish/entrypoint.sh b/.github/actions/publish/entrypoint.sh new file mode 100755 index 0000000..9a37343 --- /dev/null +++ b/.github/actions/publish/entrypoint.sh @@ -0,0 +1,4 @@ +#!/bin/sh +yarn install \ + && yarn prepublish \ + && yarn vscode:publish diff --git a/.github/actions/release/entrypoint.sh b/.github/actions/release/entrypoint.sh new file mode 100755 index 0000000..6191ac3 --- /dev/null +++ b/.github/actions/release/entrypoint.sh @@ -0,0 +1,3 @@ +#!/bin/sh +yarn install \ + && yarn run release From dd1730b1f083ec641af9bf6e7ee0c325ef2a51e7 Mon Sep 17 00:00:00 2001 From: Chase Adams Date: Thu, 23 Apr 2020 21:03:27 -0700 Subject: [PATCH 5/6] update entrypoint --- .github/actions/check/entrypoint.sh | 3 ++- .github/actions/publish/entrypoint.sh | 3 ++- .github/actions/release/entrypoint.sh | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/actions/check/entrypoint.sh b/.github/actions/check/entrypoint.sh index 8104643..498b627 100755 --- a/.github/actions/check/entrypoint.sh +++ b/.github/actions/check/entrypoint.sh @@ -1,3 +1,4 @@ -#!/bin/sh +#!/bin/sh -l + set -e yarn install && yarn test:check-code diff --git a/.github/actions/publish/entrypoint.sh b/.github/actions/publish/entrypoint.sh index 9a37343..cb4cf52 100755 --- a/.github/actions/publish/entrypoint.sh +++ b/.github/actions/publish/entrypoint.sh @@ -1,4 +1,5 @@ -#!/bin/sh +#!/bin/sh -l + yarn install \ && yarn prepublish \ && yarn vscode:publish diff --git a/.github/actions/release/entrypoint.sh b/.github/actions/release/entrypoint.sh index 6191ac3..7e4aac3 100755 --- a/.github/actions/release/entrypoint.sh +++ b/.github/actions/release/entrypoint.sh @@ -1,3 +1,4 @@ -#!/bin/sh +#!/bin/sh -l + yarn install \ && yarn run release From 4a69235913090a02c9a83e88655d80c23252b08b Mon Sep 17 00:00:00 2001 From: Chase Adams Date: Thu, 23 Apr 2020 21:07:28 -0700 Subject: [PATCH 6/6] remove entrypoint from action.yml --- .github/actions/check/action.yaml | 1 - .github/actions/release/action.yaml | 1 - 2 files changed, 2 deletions(-) diff --git a/.github/actions/check/action.yaml b/.github/actions/check/action.yaml index b62c354..57cee26 100644 --- a/.github/actions/check/action.yaml +++ b/.github/actions/check/action.yaml @@ -3,4 +3,3 @@ description: "Checks code" runs: using: "docker" image: "Dockerfile" - entrypoint: "./entrypoint.sh" diff --git a/.github/actions/release/action.yaml b/.github/actions/release/action.yaml index 2d180ed..2feb6dc 100644 --- a/.github/actions/release/action.yaml +++ b/.github/actions/release/action.yaml @@ -3,4 +3,3 @@ description: "Create Release" runs: using: "docker" image: "Dockerfile" - entrypoint: "./entrypoint.sh"