The editor uses CodeMirror, not HighlightJS.
sorry for not polishing my PR enough.
No worries!
Yes, the editor uses CodeMirror, which requires a language package with a grammar file. Then, Lezer converts this grammar into a parser that highlights code in real time.
HighlightJS can highlight static code.
Yes, the editor uses CodeMirror, which requires a language package with a grammar file. Then, Lezer converts this grammar into a parser that highlights code in real time.
There is no CodeMirror language extension for GDScript at the moment, as far as I know.
@dem4ron does it mean that there will be no syntax highlighting in the online editor? Or can we create our own GDScript module (like with HighlightJS) ?
There won’t be syntax highlighting in the online editor until we have a NPM package for the CodeMirror plugin published . There’s also some internal plumbing that needs to be done to load the package.
Yes, without a codemirror language package we won’t have highlighting in the editor, but making a language pack is absolutely doable.
Sorry for a long break ;)
I just merged a PR that swaps expected and actual values in exercises (a follow-up to swapping them in the test runner repo). Thanks @BNAndras for a review ;)
I think the most important part that is still missing is all the documentation. I will start adding PRs next.
Regarding the highlighting issue in the online editor: do you think it’s a blocker for the release of the track? These days, I usually solve exercises in the web editor, so for me it would be annoying, but not impossible to work this way. But perhaps more users prefer to solve the exercises locally, and they wouldn’t care about the online editor?
I am not sure how much effort it will be to make our own language pack, I’m trying to focus on the things we absolutely need for the track to go public ;)
It’s nice to have but it’s not part of the launch list at the end of the day. A CM6 mode is a large undertaking. Maybe there’s a similar enough NPM package already. Racket uses a Scheme one if I remember correctly.
Wow, I’ve really neglected GDScript I apologize for my long period of absence. I am still interested in seeing this track released, and I’ll do my best to start reviewing the PRs and adding new ones, so we can get this done. Hopefully I’ll have enough capacity to do it relatively smoothly …
Just let us know if you need help with anything at all.
I’d be happy to help beta-test this track and also proofread the docs, if y’all have a use for either of these roles. =)
An overview of how tracks are set up can be found at Building Tracks | Exercism's Docs. The GitHub repo is at GitHub - exercism/gdscript: Exercism exercises in GDScript. if you wanted to take a look at the docs and exercises so far. To directly interact with the track on Exercism before launch, you’ll need to be a maintainer on at least one track. However, you can do plenty with just the GitHub repo after poking through the docs I linked and any track-specific docs in the repo itself
Thanks @BNAndras ! I’m getting started on it today with your links. I realized I needed to install the test runner separately, but its readme seemed to include some unwanted generic template text (here’s a PR to remove it, if you like — sorry for creating it before discussing here, I’m still getting used to that at Exercism ) — according to the template text itself, it’s normally removed.
For the track repo, is it OK to make PRs for documentation touch-ups directly, given that the auto-closer is turned off there? Or would it still be better to start a thread here first? E.g. I think there’s some Kramdown misformatting in the instructions of resistor-color-duo and resistor-color-trio.
Yeah, that’s usually replaced with something more readable. python/README.md at main · exercism/python · GitHub is usually when I try and adapt.
You could just post within this thread if it’s related to the effort of launching this track. Then we can let you know if something’s worth doing or not or point you in the right direction. For example, the Markdown situation might be remedied by using Configlet | Exercism's Docs to sync the latest exercise documentation from the problem specifications repo all Exercism tracks pull from for practice exercises. I’d avoid editing the track exercise docs directly since they might get overwritten when a maintainer syncs the repo using configlet.
Ah, your Python link seems to be about the main track repo. I just mean the test-runner (Python’s for comparison) — you can see point 3 says: “Remove this Exercism Test Runner Template section from the README.md
file.” That’s all my PR did.
Will do on posting in this thread. About using configlet to sync the pan-Exercism docs to the GDScript track, is that something I should wait for a maintainer to do, or would you welcome me trying that and putting in a PR with the results (assuming they look reasonable)? If the problem is upstream I can try to suggest the fix there, either way.
While a track is WIP, only the maintainers (and staff?) would have write access. @pfertyk is the maintainer at the moment, but if you’re interested, the staff can add you as a maintainer as well. Then you can merge PRs as needed.
Sure, sounds good, thanks! Syncing with upstream can be my first task. :)
And I assume I probably won’t need write access on the test runner. Could you merge Remove template section from README.md by codingthat · Pull Request #48 · exercism/gdscript-test-runner · GitHub after all, then?
Also, is it OK for me to start opening PRs for stuff like the following?
BTW, I tried to follow the recent commits one-per-exercise-sync pattern with that commit, but I wonder if it’s OK to do a bulk update when syncing?