Skip to content

Conversation

jhpratt
Copy link
Contributor

@jhpratt jhpratt commented Mar 29, 2017

#1449

I probably missed something, but it just adds in a few keywords from JS.

@elextr
Copy link
Member

elextr commented Apr 6, 2017

This could probably go on the wiki with the other filetype configurations here

@jhpratt
Copy link
Contributor Author

jhpratt commented Apr 6, 2017

Why not just make it built-in? The vast majority of users will not be searching for syntax highlighting - I didn't even know it was possible to make a custom filetype until I ran into this.

@elextr
Copy link
Member

elextr commented Jul 21, 2017

No typescriptists willing to test?

@aplumb-neurala
Copy link

I tried out the changes here and they work fine for me.

@marcooliva
Copy link

Please, how can i install this TypeScript syntax highlighting in Geany?

Copy link
Member

@ntrel ntrel left a comment

Choose a reason for hiding this comment

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

Providing this works for enough TypeScript code, I think we should merge this.
@jhpratt It would be good to resolve my review points though.

[keywords]
# all items must be in one line
primary=break case catch class const continue debugger default delete do else enum export extends extend false finally for function get if import in Infinity instanceof let NaN new null return set static super switch this throw true try typeof undefined var let while with yield prototype async await declare aliased interfaced Alias Interface interface
secondary=Array Boolean boolean Date Function Math Number number Object String string RegExp EvalError Error RangeError ReferenceError SyntaxError TypeError URIError constructor prototype decodeURI decodeURIComponent encodeURI encodeURIComponent eval isFinite isNaN parseFloat parseInt protected public private keyof void any never readonly as
Copy link
Member

Choose a reason for hiding this comment

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

Each of these keyword lists are not sorted properly. I'm not sure if Scintilla requires sorted lists for correct operation.

# %e will be replaced by the filename without extension
# (use only one of it at one time)
#FT_02_LB=_Lint
#FT_02_CM=jshint "%f"
Copy link
Member

Choose a reason for hiding this comment

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

Are there no commands to compile/check a typescript file has valid syntax?

@@ -0,0 +1,54 @@
# based on JavaScript file
Copy link
Member

Choose a reason for hiding this comment

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

This file needs to be listed in data/Makefile.am.

@ntrel
Copy link
Member

ntrel commented Jun 7, 2019

@jhpratt Plus resolve the conflict please if possible. Thanks for submitting this BTW.

@marcooliva Download the filetypes.TypeScript.conf file and put it in either your user or system config directory - you can find these at the top of Help->Debug Messages. Then just restart Geany. To recognise *.ts, you also have to edit Tools->Config Files->filetype_extensions.conf, see the Files changed tab here.

@jhpratt
Copy link
Contributor Author

jhpratt commented Jun 7, 2019

@ntrel I've long since moved on from Geany. I find VS Code far superior. It's been a couple years since I submitted this PR, so a good number of changes may be out of date as well. If you'd like this conflict resolved, you should be able to edit the PR. If not, feel free to use my changes at your discretion.

@ntrel
Copy link
Member

ntrel commented Aug 17, 2019

implemented in #2187

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

Successfully merging this pull request may close these issues.

5 participants