How do I get visual studio code to run a programming language that I created? - visual-studio-code

I'm trying to get the visual studio code IDE to support a programming language that I created using python. I want vscode to have basic language and intellisense support for my language. Also, I would like the program to use the .csap file extension. Less importantly, I am interested in making a debugger extension.
Its a very simple programming language with print statements, loops, input, conditions, and some of my own built-in functions.
It is very similar to python. I have it working in my terminal right now.
What are the most important ideas for me to know about to make these extensions? What are the best resources and tutorials on the subject?
If you believe this post is to broad, please advise me on how to make it more specific.

You need the entire ecosystem for your new language, so I see at least 2, maybe 3 kind of extensions, and could look these resources:
Syntax Highlight:
https://code.visualstudio.com/api/language-extensions/syntax-highlight-guide
https://code.visualstudio.com/api/language-extensions/semantic-highlight-guide
Intellisense like features:
https://code.visualstudio.com/api/language-extensions/programmatic-language-features
https://code.visualstudio.com/api/language-extensions/language-server-extension-guide
Debugger
https://code.visualstudio.com/api/extension-guides/debugger-extension
This repo (https://github.com/microsoft/vscode-extension-samples) contains a lot of samples, and is a great source of information.
Hope this helps

Related

VS Code formatting plugins

Is there a way in VS Code to format code according to the style that a person prefers? I guess there might be a plugin for this sort of thing but I've not found that.
For example, I prefer 'K&R' coding style while a colleague prefers 'Whitesmiths' style. When we share code or functions it would be nice to autoformat code into the style that each prefers.
This does not seem like it should be so difficult for a plugin to do except that coding style also has to parse the language of the code, so Whitesmiths PowerShell is going to be different from Whitesmiths on Perl I would imagine.
Are there any plugins like this (or internal functionality in VS Code - it's a very comprehensive tool without installing any plugins of course!) that people use regularly like this?
In contrast to its name, "JIndent" (commercial) is a tool I've been using for the exact purpose you're asking about.

VS Code: Looking for an axtension to group other extensions by programming language

Okay, I know the title is not very clear, but is hard to describe what I need, so I'll try to describe it better:
I use a lot of programming languages due to my studies at the university, and my favorite editor is visual studio. The problem is, I don't want to overload it with a lot of active extensions at the same time. Therefore, the idea I came up with is an extension that creates "sessions" (or something like that) depending on what programming language I want to use. For example, imagine I want to use python, then I'd turn on an option which will enable the extensions needed for python and it will disable the remaining ones.
I can't find any similar extension on Google, I don't know if I am using the correct keywords for that, though. So, if you know of something that will help me, let me know please.

Creating a plugin for code hinting

I'm working with an internally-developed scripting language that some prof and his team have created for an academic project. There's documentation that show function signatures of the existing classes, but for outsiders like me, I'm constantly referring to documentation. Also, in the summer, more helpers will join and I bet they will all suffer from the same problem. So I'd like to write something in Eclipse to help with code hinting and completion, like many languages have.
I haven't programmed eclipse add-ons before, so can someone give me hints how I would generally take the function signatures from their documentation and get code hinting from it. I realize I may need to make changes to the documentation to use it for what I need. But any hints or sample projects would be appreciated. I'm not sure how to get started.
You should have a look at Xtext. With Xtext you can define a domain specific language and generate an editor for it. Here you can find a brief tutorial.

Writing custom IDE on top of Eclipse

I wish to write my own Python IDE (just for the heck of it). I was wondering if I could use Eclipse as a foundation. This will save me from coding a whole lotta things (code editor, intellisense and so on).
To understand what I mean, please take a look at Visual Studio Isolated Shell. I'm essentially looking for something equivalent. Searching on Google hasn't helped. Is there anything like this available in Eclipse's case?
Yes. Eclipse is designed to have additional languages added and there is extensive support for this kind of plugin development. I'm surprised Googling didn't help - there's an entire site dedicated to a tutorial on the basics and a toolkit for developing such things

Is there a VSCode equivalent to Notepad++'s user defined language configuration?

I really enjoyed defining syntax highlighting rules in Notepad++ for the various build logs and artifacts I've worked on in the past to make certain text markers pop out. I was wondering if VSCode has any capabilities to do likewise.
For reference to the unfamiliar here's the Notepad++ documentation and a live demonstration:
https://npp-user-manual.org/docs/user-defined-language-system/
How to Create Custom Language Definitions in Notepad++
Looks like there is support for something in this direction. The terminology is slightly different though and there may not be a GUI interface like Notedpad++
Declarative Language Feature
Syntax Highlight Guide: VS Code uses TextMate grammar for syntax highlighting. This guide will walk you through writing a simple TextMate grammar and converting it into a VS Code extension.
Create Custom Language in Visual Studio Code
https://code.visualstudio.com/api/language-extensions/overview#declarative-language-features
https://code.visualstudio.com/api/language-extensions/language-configuration-guide