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

I added PineScript support #25

Closed
Fred-Vatin opened this issue Oct 16, 2024 · 2 comments
Closed

I added PineScript support #25

Fred-Vatin opened this issue Oct 16, 2024 · 2 comments

Comments

@Fred-Vatin
Copy link

Fred-Vatin commented Oct 16, 2024

Hi,

Thanks a lot for this plugin. Now I can add missing languages.

Here is how I added PineScript support:

  • Download pine.tmLanguage.json from the great VS Code extension.
  • Open the file and change the name to pine instead of Pine Script
  • Put it on a folder inside your vault and reference it in shiki settings, for instance /MyScripts/Shiki/Languages/
  • Follow the readme about how to add custom language.
  • Restart Obsidian

You’ll need an enhanced theme to highlight some keywords. You can find one in the same repo as above. Or in my VS Code theme here. If importing those files doesn’t work directly, install the needed themes in VS Code then run this command from palette: Generate color theme from current settings. A new file is open in VS Code with the theme. Search for comments and delete them then save the file as .json and NOT .jsonc. It worked for me.

I wonder if this language can be integrated in the plugin so every user can has it by default.

@mProjectsCode
Copy link
Owner

I wonder if this language can be integrated in the plugin so every user can has it by default.

No. The plugin will only ship with languages that ship with shiki. The plugin is sadly already very big.

@Fred-Vatin
Copy link
Author

I made a request to their TextMate repo: shikijs/textmate-grammars-themes#97

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants