-
-
Notifications
You must be signed in to change notification settings - Fork 242
vscode addon for formatting and highlighting #81
-
it would be nice if you made a vscode addon for Nilesoft Shell Script (.shl).
it would add simple text highlighting and support for:
- collapsing
{...}and multi-line items - maybe IntelliSense
(also, it would be nice if you had a discord server👍)
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 15 comments 35 replies
-
i'm looking into it and i think i might beable to do it myself.
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 2
-
This would be a really great contribution
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1
-
Hi, I've made a vscode extension for that. With a grammar, if you wanna try.
I'm new to this, but it seems to work well :-)
Screenshot 2023年05月25日 142811
Folding works, comments and hightlighting of some elements is supported.
I can give you the code if you want to use it as a starter.
Beta Was this translation helpful? Give feedback.
All reactions
-
❤️ 1
-
This is a really great contribution
Beta Was this translation helpful? Give feedback.
All reactions
-
You can add this extension to the vscode folder inside the extensions folder
Beta Was this translation helpful? Give feedback.
All reactions
-
I don't have rights to create a branch.
Beta Was this translation helpful? Give feedback.
All reactions
-
nice, i will use that.
Beta Was this translation helpful? Give feedback.
All reactions
-
Fixed variables not colored:
updated vsix extension
Also added snippets (me/it) for menu/item
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1
-
i understand what you did.
the file extension is not .nss it's .shl
Beta Was this translation helpful? Give feedback.
All reactions
-
line 22, change to .shl in package.json
Beta Was this translation helpful? Give feedback.
All reactions
-
You mean the extensions of files for nilesoft shell ?
I think it is .nss because it is what is specified in documentation and also in the example files delivered by the setup : Doc
By the way, you can switch to nilesoft in the vscode state bar even if it is the wrong extension no ?
Beta Was this translation helpful? Give feedback.
All reactions
-
@ChristopheL77 the newest versions
0.0.5and0.1.0don't do anything. I can't get the old ones, link expired
Sorry for expired links. I thought I could put it in github but I can't create a branch right now.
Beta Was this translation helpful? Give feedback.
All reactions
-
I published it on the market place, you should be able to install it from vscode now
Beta Was this translation helpful? Give feedback.
All reactions
-
❤️ 2
-
that is weird, my nilesoft download has shell.shl as the file.
also, i found a bug when you have smth like a='@myFnc("b")' it doesn't like the quotes or smth.
Beta Was this translation helpful? Give feedback.
All reactions
-
i found a bug when you have smth like
a='@myFnc("b")'it doesn't like the quotes or smth.
Yes I didn't find a regular expression to match these expressions because nss language allows to break item/menu properties into multiple lines mixed with properties in same line and there is not an end of statement char as far as I know. I'm still trying though ;)
I mean we can do
menu(prop1=abc())
menu(prop1=abc()
prop2=def
)
menu(prop1=abc(aa()) prop2=def
)
menu(prop1=abc prop2=def()
)
And I have to identity the last parenthesis to know where the menu properties ends.
Here, the right parenthesis may be interpreted as the end of menu or item properties that's why it doesn't highlight well after.
Beta Was this translation helpful? Give feedback.
All reactions
-
i have 1.7 rn. how do i update it?
Beta Was this translation helpful? Give feedback.
All reactions
-
winget update nilesoft.shell
Or others methods : https://nilesoft.org/download
Backup your config files before if you updated them.
Beta Was this translation helpful? Give feedback.
All reactions
-
could you add the nilesoft icon to the file extension?
Beta Was this translation helpful? Give feedback.
All reactions
-
i found a bug when you have smth like
a='@myFnc("b")'it doesn't like the quotes or smth.
I think it is fixed now in v1.1.0
I learned about regular expression recursion ;-)
Beta Was this translation helpful? Give feedback.
All reactions
-
Yes if @moudey allows me to use his icon.
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1
-
Yes you can
Beta Was this translation helpful? Give feedback.
All reactions
-
Cool ;). Updated in v1.0.1
Beta Was this translation helpful? Give feedback.
All reactions
-
that is not what i meant. i meant for the files so you can see that they are nilesoft shell files instead of just this:
image
Beta Was this translation helpful? Give feedback.
All reactions
-
Done in 1.2.0 ;)
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1
-
Beta Was this translation helpful? Give feedback.
All reactions
-
❤️ 1
-
Updated to 1.5.0 with autocompletion with documentation (based on nilesoft doc)
Beta Was this translation helpful? Give feedback.
All reactions
-
@ChristopheL77 i would like to get access to the extension repo so i can fix some things.
Beta Was this translation helpful? Give feedback.
All reactions
-
What do you want to fix ?
Send me your email address so I can add you to project.
Beta Was this translation helpful? Give feedback.
All reactions
-
are you in the nilesoft discord?
also, i don't think you need an email, you can enter username, full name, or email.
just use my username @Natejoestev
Beta Was this translation helpful? Give feedback.
All reactions
-
unless your planning to add me as a contributor to the marketplace.
Beta Was this translation helpful? Give feedback.
All reactions
-
Beta Was this translation helpful? Give feedback.
All reactions
-
can we talk on discord?
Beta Was this translation helpful? Give feedback.
All reactions
-
my username is @natejoestev
Beta Was this translation helpful? Give feedback.
All reactions
-
Check out my Notepad++ theme for Shell & Python: https://discord.com/channels/1106387012707168318/1241063722449899712
Beta Was this translation helpful? Give feedback.
All reactions
-
@ChristopheL77 do you plan make the NS vscode extension even better?
Beta Was this translation helpful? Give feedback.
All reactions
-
Beta Was this translation helpful? Give feedback.
All reactions
-
Тhanks to text highlighting the code is easily recognizable - without it it would be much more difficult - very good job. But I personally use regex, reg paths, ps commands ... - sometimes they make highlighting "stop" for a few lines, or change the coloring, some new commands are not colored, auto-completion only works on basic commands ... definitely many things can be improved. If you decide to work on improving the extension I would like to help
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1
-
Beta Was this translation helpful? Give feedback.
All reactions
-
👀 1
-
I won't have time in the next few months. I'll need time to get familiar with azure devops and the extension structure before I start changing anything on my own. You can add me to the project now or I'll write to you again when I have time to take on the project more seriously. Find me in discord with the same name (I don't want to use the program page as a general chat)
Beta Was this translation helpful? Give feedback.
All reactions
-
👀 1
-
This is really awesome. How difficult would it be to release this as a syntax definition package for Sublime Text?
Beta Was this translation helpful? Give feedback.
All reactions
-
I don't know at all. I never used sublime nor did an extension for it. Sorry.
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1
-
Is your extension open source? If so I'd be happy to fork and port it over to sublime text for those of us who don't use vscode
Beta Was this translation helpful? Give feedback.
All reactions
-
I can give you access to source code, it is hosted on azure devops (I need an email address).
Beta Was this translation helpful? Give feedback.
All reactions
-
Sure. Here is a throwaway email I use (to avoid publishing my primary): inthat650@gmail.com
Beta Was this translation helpful? Give feedback.
All reactions
-
I will maintain one branch for editor-agnostic commits in case you'd like to merge any of them into your repo.
Beta Was this translation helpful? Give feedback.
All reactions
-
👍 1