Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON Schema for Tact configuration #194

Merged
merged 22 commits into from
Mar 27, 2024
Merged

Conversation

VanishMax
Copy link
Contributor

Closes #178

Added:

  • JSON Schema
  • Tests for JSON schema with Ajv validator

Future work:

@anton-trunov anton-trunov requested a review from novusnota March 26, 2024 16:49
@anton-trunov anton-trunov self-assigned this Mar 26, 2024
@anton-trunov anton-trunov added ux scope: tooling Language tooling labels Mar 26, 2024
Copy link
Member

@anton-trunov anton-trunov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome stuff! Please keep it coming 👍

I only have a minor comment below. And perhaps @novusnota as the author of the corresponding issue will add his "2 cents" :)

src/test/schema.spec.ts Outdated Show resolved Hide resolved
@anton-trunov anton-trunov added this to the v1.3.0 milestone Mar 26, 2024
@novusnota
Copy link
Member

novusnota commented Mar 26, 2024

Swiftly done, nice work @VanishMax! I'm in the process of reviewing and your schema works just great:

image

I see that you took descriptions from the documentation, but could you please clarify, which ones were incorrect? I'd like to re-write that page in the near future, but until then it would be nice to enhance the descriptions in the Schema here — I'll send a couple of suggestions in a moment or two :)

Copy link
Member

@novusnota novusnota left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome work @VanishMax! Just a few improvements, which you may commit all at once (from "Files changed" tab):

  • Adjusted descriptions
  • Added links to docs, where possible or sensible, see:

image

Note, that such links are clickable in IDEs, modern terminals and editors, such as Neovim or Helix. Therefore, it's nice to add links in such descriptions whenever possible :)

grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
grammar/configSchema.json Outdated Show resolved Hide resolved
VanishMax and others added 12 commits March 27, 2024 09:51
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
Co-authored-by: Novus Nota <68142933+novusnota@users.noreply.github.com>
.github/workflows/tact.yml Outdated Show resolved Hide resolved
src/grammar/grammar.format-spec.ts Outdated Show resolved Hide resolved
src/test/schema.format-spec.ts Outdated Show resolved Hide resolved
@anton-trunov anton-trunov added the scope: ci Continuous Integration: GitHub Actions (.github), commit/push hooks (.husky) label Mar 27, 2024
@anton-trunov
Copy link
Member

I think this also deserves an entry in CHANGELOG.md

novusnota
novusnota previously approved these changes Mar 27, 2024
Copy link
Member

@novusnota novusnota left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀

@novusnota novusnota requested a review from anton-trunov March 27, 2024 20:26
src/test/test-tact.config.json Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
Copy link
Member

@anton-trunov anton-trunov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your contribution! Btw, this qualifies for the Tact contributor SBT: https://society.ton.org/contribute-to-tact-compiler. I'll just need your TON wallet address to issue the SBT

@anton-trunov anton-trunov merged commit fb907c4 into tact-lang:main Mar 27, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: ci Continuous Integration: GitHub Actions (.github), commit/push hooks (.husky) scope: tooling Language tooling
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create a JSON schema for tact.config.json
3 participants