Skip to content

Commit

Permalink
Add grammars and snippets JSON
Browse files Browse the repository at this point in the history
  • Loading branch information
lefessan committed Apr 7, 2023
1 parent 425f6b4 commit e9514dd
Show file tree
Hide file tree
Showing 27 changed files with 721 additions and 116 deletions.
70 changes: 40 additions & 30 deletions .drom
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@ version:0.9.0

# hash of toml configuration files
# used for generation of all files
6c4745d9b958fd36a74ce5a34f13a6d2:.
297b83c58854bc74c95224ad4d59312a:.
# end context for .

# begin context for .github/workflows/workflow.yml
# file .github/workflows/workflow.yml
3c16bbaff1158ecfc19480e0744aaf2a:.github/workflows/workflow.yml
2986d80caed72cdc485bf24526c80c81:.github/workflows/workflow.yml
# end context for .github/workflows/workflow.yml

# begin context for .gitignore
# file .gitignore
a9baccd9eedd2f924ca9b9879b70c3e0:.gitignore
fef04f16f98ac1ba77b226e28deeaedc:.gitignore
# end context for .gitignore

# begin context for CHANGES.md
Expand All @@ -30,7 +30,7 @@ d00f73c835ae4a1589d55ebda4ab381b:CHANGES.md

# begin context for Makefile
# file Makefile
923cec84b4c88ee7a39817739aa83cb0:Makefile
d768fb221fd49646ac83e91c15640e63:Makefile
# end context for Makefile

# begin context for README.md
Expand All @@ -50,7 +50,7 @@ edfecf246f5178999b757bb30a11aaba:drom.toml

# begin context for dune-project
# file dune-project
7147afeddc222b46b556c83201c1e4d5:dune-project
22a083c5f6206cf0e56c1889aa306ee0:dune-project
# end context for dune-project

# begin context for opam/interop-js-stubs.opam
Expand Down Expand Up @@ -83,11 +83,21 @@ dcf0ebaa8b12787df9efcaa0ce8cbbe5:opam/package-json.opam
b439593de026c1aff0dad24461c827b3:opam/vscode-js-stubs.opam
# end context for opam/vscode-js-stubs.opam

# begin context for opam/vscode-json.opam
# file opam/vscode-json.opam
1e7a6028ac6526885fcfdfdcdfa3bd63:opam/vscode-json.opam
# end context for opam/vscode-json.opam

# begin context for opam/vscode-languageclient-js-stubs.opam
# file opam/vscode-languageclient-js-stubs.opam
b2c08001aca6fbb3ce109c87fc2896ec:opam/vscode-languageclient-js-stubs.opam
# end context for opam/vscode-languageclient-js-stubs.opam

# begin context for opam/vscode-package-json.opam
# file opam/vscode-package-json.opam
322332c2d6ea5ade8adbfb82587adb86:opam/vscode-package-json.opam
# end context for opam/vscode-package-json.opam

# begin context for scripts/after.sh
# file scripts/after.sh
62c6489217feef26dac343e709b89c1a:scripts/after.sh
Expand Down Expand Up @@ -138,31 +148,6 @@ cf30d5557250e864c9020afd9e2389fd:src/node-js-stubs/dune
940d29cde7f16cd0916ed1d5f9c41154:src/node-js-stubs/version.mlt
# end context for src/node-js-stubs/version.mlt

# begin context for src/package-json/dune
# file src/package-json/dune
9f4e3c0bfa0afc5164a25346c401380b:src/package-json/dune
# end context for src/package-json/dune

# begin context for src/package-json/linking_flags.sh
# file src/package-json/linking_flags.sh
c7aa7ad8967d43dd0e7ea2f013af7376:src/package-json/linking_flags.sh
# end context for src/package-json/linking_flags.sh

# begin context for src/package-json/main.ml
# file src/package-json/main.ml
dd19135f4f49d3c99b5658d0e58f4460:src/package-json/main.ml
# end context for src/package-json/main.ml

# begin context for src/package-json/package.toml
# file src/package-json/package.toml
1ce8790167330967a712ed12f27f26c3:src/package-json/package.toml
# end context for src/package-json/package.toml

# begin context for src/package-json/version.mlt
# file src/package-json/version.mlt
940d29cde7f16cd0916ed1d5f9c41154:src/package-json/version.mlt
# end context for src/package-json/version.mlt

# begin context for src/polka-js-stubs/dune
# file src/polka-js-stubs/dune
569424afbc851a410f6f388591417035:src/polka-js-stubs/dune
Expand Down Expand Up @@ -213,6 +198,16 @@ f8e015ab8ad6d1dc7c7c8d63c86e446d:src/vscode-js-stubs/dune
940d29cde7f16cd0916ed1d5f9c41154:src/vscode-js-stubs/version.mlt
# end context for src/vscode-js-stubs/version.mlt

# begin context for src/vscode-json/dune
# file src/vscode-json/dune
a18d965350ea19e9be91b3784887f1ef:src/vscode-json/dune
# end context for src/vscode-json/dune

# begin context for src/vscode-json/version.mlt
# file src/vscode-json/version.mlt
940d29cde7f16cd0916ed1d5f9c41154:src/vscode-json/version.mlt
# end context for src/vscode-json/version.mlt

# begin context for src/vscode-languageclient-js-stubs/dune
# file src/vscode-languageclient-js-stubs/dune
935c7469b455b26a8ec1f08627aae863:src/vscode-languageclient-js-stubs/dune
Expand All @@ -227,3 +222,18 @@ f8e015ab8ad6d1dc7c7c8d63c86e446d:src/vscode-js-stubs/dune
# file src/vscode-languageclient-js-stubs/version.mlt
940d29cde7f16cd0916ed1d5f9c41154:src/vscode-languageclient-js-stubs/version.mlt
# end context for src/vscode-languageclient-js-stubs/version.mlt

# begin context for src/vscode-package-json/dune
# file src/vscode-package-json/dune
1418db38f60b30eacfab7a22d0cc2ad7:src/vscode-package-json/dune
# end context for src/vscode-package-json/dune

# begin context for src/vscode-package-json/linking_flags.sh
# file src/vscode-package-json/linking_flags.sh
c7aa7ad8967d43dd0e7ea2f013af7376:src/vscode-package-json/linking_flags.sh
# end context for src/vscode-package-json/linking_flags.sh

# begin context for src/vscode-package-json/version.mlt
# file src/vscode-package-json/version.mlt
940d29cde7f16cd0916ed1d5f9c41154:src/vscode-package-json/version.mlt
# end context for src/vscode-package-json/version.mlt
2 changes: 1 addition & 1 deletion .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:

- run: opam pin add . -y --no-action

- run: opam depext -y superbol-vscode-extension polka-js-stubs interop-js-stubs node-js-stubs vscode-js-stubs vscode-languageclient-js-stubs package-json
- run: opam depext -y superbol-vscode-extension polka-js-stubs interop-js-stubs node-js-stubs vscode-js-stubs vscode-languageclient-js-stubs vscode-package-json vscode-json
# if: steps.cache-opam.outputs.cache-hit != 'true'

- run: opam install -y opam/*.opam --deps-only --with-test
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
/node-js-stubs
/vscode-js-stubs
/vscode-languageclient-js-stubs
/package-json
/vscode-package-json
/vscode-json
*~
_build
.merlin
Expand All @@ -17,6 +18,7 @@ _build
/node_modules
/yarn-error.log
/yarn.lock
/package-json
ATTIC


2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ all: build
build:
./scripts/before.sh build
opam exec -- dune build @install
./scripts/copy-bin.sh superbol-vscode-extension polka-js-stubs interop-js-stubs node-js-stubs vscode-js-stubs vscode-languageclient-js-stubs package-json
./scripts/copy-bin.sh superbol-vscode-extension polka-js-stubs interop-js-stubs node-js-stubs vscode-js-stubs vscode-languageclient-js-stubs vscode-package-json vscode-json
./scripts/after.sh build

build-deps:
Expand Down
2 changes: 1 addition & 1 deletion Makefile.header
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ SRCDIR=src/superbol-vscode-extension

compile:
opam exec -- dune build
cp -f _build/default/src/package-json/main.exe package-json
cp -f _build/default/src/vscode-package-json/main.exe vscode-package-json
yarn esbuild _build/default/$(SRCDIR)/$(PROJECT).bc.js \
--bundle \
--external:vscode \
Expand Down
7 changes: 6 additions & 1 deletion drom.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ dot-gitignore-trailer = """
/node_modules
/yarn-error.log
/yarn.lock
/package-json
ATTIC
"""

Expand Down Expand Up @@ -106,6 +107,10 @@ dir = "src/vscode-languageclient-js-stubs"
# edit 'src/vscode-languageclient-js-stubs/package.toml' for package-specific options

[[package]]
dir = "src/package-json"
dir = "src/vscode-package-json"
# edit 'src/package-json/package.toml' for package-specific options

[[package]]
dir = "src/vscode-json"
# edit 'src/package-json/package.toml' for package-specific options

19 changes: 18 additions & 1 deletion dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,24 @@
)

(package
(name package-json)
(name vscode-package-json)
(synopsis "The superbol-vscode-extension project")
(description "This is the description\nof the superbol-vscode-extension OCaml project\n")
(depends
(ocaml (>= 4.13.0))
(vscode-json (= version))
ezjsonm
(ez_file (and (>= 0.3.0) (< 1.0.0)))
ppx_deriving_encoding
ppx_inline_test
ppx_expect
odoc
ocamlformat
)
)

(package
(name vscode-json)
(synopsis "The superbol-vscode-extension project")
(description "This is the description\nof the superbol-vscode-extension OCaml project\n")
(depends
Expand Down
49 changes: 49 additions & 0 deletions opam/vscode-json.opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# This file was generated by `drom` from `drom.toml`.
# Do not modify, or add to the `skip` field of `drom.toml`.
opam-version: "2.0"
name: "vscode-json"
version: "0.1.0"
license: "MIT"
synopsis: "The superbol-vscode-extension project"
description: """\
This is the description
of the superbol-vscode-extension OCaml project
"""
authors: ["Fabrice Le Fessant <[email protected]>"]
maintainer: ["Fabrice Le Fessant <[email protected]>"]
homepage: "https://ocamlpro.github.io/superbol-vscode-extension"
doc: "https://ocamlpro.github.io/superbol-vscode-extension/sphinx"
bug-reports: "https://github.com/ocamlpro/superbol-vscode-extension/issues"
dev-repo: "git+https://github.com/ocamlpro/superbol-vscode-extension.git"
tags: "org:ocamlpro"
build: [
["dune" "subst"] {dev}
["sh" "-c" "./scripts/before.sh build '%{name}%'"]
[
"dune"
"build"
"-p"
name
"-j"
jobs
"@install"
"@runtest" {with-test}
"@doc" {with-doc}
]
["sh" "-c" "./scripts/after.sh build '%{name}%'"]
]
install: [
["sh" "-c" "./scripts/before.sh install '%{name}%'"]
]
depends: [
"ocaml" {>= "4.13.0"}
"dune" {>= "2.7.0"}
"ezjsonm" {}
"ez_file" {>= "0.3.0" & < "1.0.0"}
"ppx_deriving_encoding" {}
"ppx_inline_test" {with-test}
"ppx_expect" {with-test}
"odoc" {with-doc}
"ocamlformat" {with-test}
]
# Content of `opam-trailer` field:
50 changes: 50 additions & 0 deletions opam/vscode-package-json.opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# This file was generated by `drom` from `drom.toml`.
# Do not modify, or add to the `skip` field of `drom.toml`.
opam-version: "2.0"
name: "vscode-package-json"
version: "0.1.0"
license: "MIT"
synopsis: "The superbol-vscode-extension project"
description: """\
This is the description
of the superbol-vscode-extension OCaml project
"""
authors: ["Fabrice Le Fessant <[email protected]>"]
maintainer: ["Fabrice Le Fessant <[email protected]>"]
homepage: "https://ocamlpro.github.io/superbol-vscode-extension"
doc: "https://ocamlpro.github.io/superbol-vscode-extension/sphinx"
bug-reports: "https://github.com/ocamlpro/superbol-vscode-extension/issues"
dev-repo: "git+https://github.com/ocamlpro/superbol-vscode-extension.git"
tags: "org:ocamlpro"
build: [
["dune" "subst"] {dev}
["sh" "-c" "./scripts/before.sh build '%{name}%'"]
[
"dune"
"build"
"-p"
name
"-j"
jobs
"@install"
"@runtest" {with-test}
"@doc" {with-doc}
]
["sh" "-c" "./scripts/after.sh build '%{name}%'"]
]
install: [
["sh" "-c" "./scripts/before.sh install '%{name}%'"]
]
depends: [
"ocaml" {>= "4.13.0"}
"dune" {>= "2.7.0"}
"vscode-json" {= version}
"ezjsonm" {}
"ez_file" {>= "0.3.0" & < "1.0.0"}
"ppx_deriving_encoding" {}
"ppx_inline_test" {with-test}
"ppx_expect" {with-test}
"odoc" {with-doc}
"ocamlformat" {with-test}
]
# Content of `opam-trailer` field:
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
}
}
},
"main": "./out/superbol_vscode_extension.bc.js",
"main": "./dist/superbol_vscode_extension.bc.js",
"scripts": {
"package": "vsce package --out superbol-vscode-extension.vsix --yarn",
"deploy:vsce": "vsce publish --packagePath superbol-vscode-extension.vsix --yarn",
Expand All @@ -66,6 +66,5 @@
"prettier": "^2.5.1",
"vsce": "2.14.0",
"vscode-test": "1.6.1"
},
"icon": "assets/logo.png"
}
}
56 changes: 0 additions & 56 deletions src/package-json/main.ml

This file was deleted.

Loading

0 comments on commit e9514dd

Please sign in to comment.