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

.dib metadata support #2259

Merged
merged 5 commits into from
Sep 15, 2022
Merged

Conversation

jonsequitur
Copy link
Contributor

This fixes #2184.

@jonsequitur jonsequitur enabled auto-merge (squash) September 15, 2022 17:49
@@ -0,0 +1,27 @@
#!meta

{"kernelInfo":{"defaultKernelName":"csharp","items":[{"aliases":["cs","C#","c#"],"name":"csharp"},{"aliases":["fs","F#","f#"],"name":"fsharp"},{"aliases":["powershell"],"name":"pwsh"},{"name":"mermaid"},{"name":"javascript"}]}}
Copy link
Member

Choose a reason for hiding this comment

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

Can we format/indent this? It's kind-of meaningful to human eyes and if/when this changes, the diff will be more manageable.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes it should work if formatted over multiple lines, but I need to add a test for that.

public string? Language { get; set; }
public string? KernelName { get; set; }

// FIX: (InteractiveDocumentElement) add this back
Copy link
Member

Choose a reason for hiding this comment

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

Language won't need to be added back; it can be looked up via the metadata.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Do you mean kernel info? The goal here is to not have to spin up the kernel in order to know some of these things.

@brettfo
Copy link
Member

brettfo commented Sep 15, 2022

The bottom of NotebookTestScript.dib has a dib-writing scenario that'll need to be updated.

@jonsequitur jonsequitur merged commit 769f293 into dotnet:main Sep 15, 2022
@colombod colombod added the enhancement New feature or request label Oct 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add #!metadata kernel
3 participants