Skip to content

hyperpolymath/vscode-k9

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

vscode-k9

Overview

VS Code extension providing syntax highlighting, language configuration, and snippets for K9 contractile validator files.

K9 is the deployment validation language used by the contractile system. It supports two formats:

  • .k9 (Kennel format) — YAML-like declarative syntax for validators, recipes, and pedigree metadata

  • .k9.ncl (Yard/Hunt Nickel format) — Nickel-based programmable validators with contracts and type safety

Features

  • Two TextMate grammars: one for .k9 (Kennel) and one for .k9.ncl (Nickel)

  • Language configuration for both formats with bracket matching and comment toggling

  • 13 snippets across both languages for common K9 patterns

  • Semantic coloring for trust levels: kennel (highest), yard (medium), hunt (lowest)

  • K9 magic number (K9!) highlighting

Installation

Install from the VS Code marketplace:

ext install hyperpolymath.vscode-k9

Or install from VSIX:

code --install-extension vscode-k9-0.1.0.vsix

K9 Kennel Format (.k9)

Highlights:

Element Scope

Magic number (K9!)

keyword.control.magic

Trust levels (kennel, yard, hunt)

entity.name.type.trust-level

Pedigree fields (name, version, etc.)

keyword.other.pedigree

Security levels

constant.language.security-level

Key-value pairs

entity.name.tag / string.unquoted

Comments, strings, numbers, booleans

Standard scopes

K9 Nickel Format (.k9.ncl)

Highlights:

Element Scope

let bindings

keyword.other.let / variable.other.binding

Contracts and types

entity.name.type.contract

import statements

keyword.control.import

Record literals

punctuation.definition.record

Recipe/validator blocks

keyword.other.recipe

Security level annotations

constant.language.security-level

Nickel keywords

keyword.control

Built-in types (Str, Num, Bool, etc.)

support.type.builtin

String interpolation (%\{…​\})

meta.interpolation

Snippets

K9 Kennel (.k9)

Prefix Name Description

k9

K9 Magic Header

File header with magic number and pedigree

validator

Validator

Validator block with checks

recipe

Recipe

Recipe with inputs/outputs/constraints

dep

Dependency

Dependency entry with trust level

kennel

Kennel Trust

Set trust to kennel (highest)

yard

Yard Trust

Set trust to yard (medium)

hunt

Hunt Trust

Set trust to hunt (lowest)

K9 Nickel (.k9.ncl)

Prefix Name Description

k9ncl

K9 Nickel Validator

Complete validator template

let

Let Binding

Let binding with contract

rec

Record

Record literal

contract

Contract

Custom Nickel contract

import

Import

Import statement

recipe

Recipe

Nickel recipe block

License

SPDX-License-Identifier: MPL-2.0

(PMPL-1.0-or-later preferred; MPL-2.0 required for VS Code marketplace)

See LICENSE for the full MPL-2.0 text. See LICENSE-PMPL for the PMPL-1.0-or-later text.

About

VS Code syntax highlighting for K9 (Self-Validating Components) — .k9 and .k9.ncl files

Topics

Resources

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENSE
Unknown
LICENSE-PMPL

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors