Commit Graph

42160 Commits

Author SHA1 Message Date
Andrew Dupont
bbf5242d96 [language-typescript] Highlighting fixes for TS and TSX:
* Highlight namespaced JSX tags (e.g., `<React.Fragment>`) like other JSX tags
* Don't scope `/` punctuation in JSX tags like a division operator
* Scope ordinary functions as `support.other.function` just as in JavaScript
* Scope the last segment of `namespace` declarations as an `entity`, other segments as `support.class`
2024-01-18 13:53:23 -08:00
Andrew Dupont
e972f92636 Score a Tree-sitter grammar as -1 if they’re disabled in config 2024-01-18 13:53:23 -08:00
Andrew Dupont
95de9bc89f [language-typescript] Distinguish different usages of < and >
Angle brackets in type parameter lists (e.g., `Array<string>`) should not be scoped like comparison operators.
2024-01-18 13:53:23 -08:00
Andrew Dupont
dfb2493e43 Add some more stray .eslintrc files 2024-01-18 13:53:23 -08:00
Andrew Dupont
09184d959f Add documentation for the new TODO/hyperlink services 2024-01-18 13:53:23 -08:00
Andrew Dupont
6069a59804 Remove the requirement for a grammar to have a highlightsQuery 2024-01-18 13:53:23 -08:00
Andrew Dupont
fbc2c822ad Prevent certain Python strings from being double-scoped 2024-01-18 13:53:23 -08:00
Andrew Dupont
93ab0f7bf0 Convert all modern Tree-sitter TODO/hyperlink injections into services 2024-01-18 13:53:22 -08:00
Daeraxa
8f20fa77d3 update year 2024-01-17 22:21:04 +00:00
DeeDeeG
b7cd6304a0 CI: Build Linux binaries in a Debian 10 Docker container
For compatibility with older Linux distros

Debian 8 is pretty much end-of-life now.
Debian 10 should be old enough to have compatible glibc for RHEL 8.
2024-01-16 14:12:13 -05:00
Clayton Carter
ae03e1e9ba fix(tree-sitter): pass node text to grammar
This fixes a subtle breaking change in the WASM tree-sitter modes that
affected the semanticolor package. (And probably only that package.)

Although the node text is unused in `idForScope` in the core editor, the
legacy tree-sitter mode was specifically modified to pass the node text
into `idForScope` so that the semanticolor package could make use of it
to give custom scopes (and thus colors) to different symbols. (On
activation, semanticolor monkey patches that method in relevant
grammars.)

This alone is not enough to get sematicolor working with Pulsar's new
WASM tree-sitter modes, but it's one piece of the puzzle.

Ref: 97b905a2b0
Ref: https://github.com/atom/atom/pull/20212
Ref: 1bf7fc4025/src/tree-sitter-language-mode.js (L1321-L1324)
Ref: d219ef9a1f/lib/semanticolor-grammar.js (L44-L65)
2024-01-16 07:42:16 -05:00
confused_techie
64175c5271
Merge pull request #865 from pulsar-edit/v1.113.0-release
v1.113.0 Release
2024-01-15 20:10:15 -08:00
confused-Techie
95684f661e Add back dev 2024-01-15 20:09:52 -08:00
confused-Techie
3f449b4401 Bump package.json version 2024-01-15 17:12:43 -08:00
confused_techie
691dd539be
Merge pull request #862 from pulsar-edit/changelog-1.113.0
1.113.0 Changelog
2024-01-15 17:09:39 -08:00
confused-Techie
35a826b851 Add last minute PR update 2024-01-15 17:05:58 -08:00
confused_techie
1e942eed06
Merge pull request #864 from savetheclocktower/symbols-view-go-back-fix
[symbols-view] Fix issue with returning from a declaration
2024-01-15 17:04:25 -08:00
confused-Techie
d9179f583d Add Modern Tree-sitter notice 2024-01-15 16:11:53 -08:00
confused-Techie
a2ceec802a Fix formatting of find-and-replace contribution 2024-01-15 16:08:44 -08:00
confused-Techie
490e826307 Add Changelog 2024-01-15 16:03:59 -08:00
Andrew Dupont
039ea260b2 [symbols-view] Add specs for return-from-declaration fix 2024-01-15 16:01:47 -08:00
Andrew Dupont
a720d967d7 [symbols-view] Fix issue with returning from a declaration…
…when the tab being returned to is closed and must be recreated.
2024-01-15 15:43:06 -08:00
Andrew Dupont
7dd52e57be
Merge pull request #852 from savetheclocktower/add-php-grammar
Tree-sitter fixes for December (including a PHP grammar!)
2024-01-13 17:13:07 -08:00
Andrew Dupont
0111e13f0e PHP feedback 2024-01-12 19:38:28 -08:00
Andrew Dupont
6ebdfa0cab Remove unneeded file 2024-01-12 19:33:38 -08:00
Andrew Dupont
bae3689f88 Add folds for PHP 2024-01-12 19:33:20 -08:00
Andrew Dupont
f3be33bbc9 Add <> and <=> operators in PHP 2024-01-12 19:21:00 -08:00
Andrew Dupont
62bd6cc8ba Even more PHP grammar feedback 2024-01-12 17:11:49 -08:00
Andrew Dupont
e78feea098 Address more PHP grammar feedback 2024-01-12 14:25:42 -08:00
Andrew Dupont
a34b01bfb2 In JS/TS, correctly highlight a variable with a default value…
…when destructuring an array.
2024-01-12 13:28:22 -08:00
Andrew Dupont
99722454b8 [symbols-view] Allow for scope-specific overrides of preferred providers 2024-01-12 13:10:51 -08:00
Andrew Dupont
ddfa645122 Fix issue where symbol-provider-ctags used the wrong package root 2024-01-12 12:42:01 -08:00
Andrew Dupont
865153b471 Address newly failing tests 2024-01-11 16:08:37 -08:00
Andrew Dupont
50bfa5141e Update tree-sitter-json WASM build to latest
Spotted it falling down on a very large JSON file I had. Seems to be fixed on `master`. Not sure which verison I originally built it from.
2024-01-11 15:07:11 -08:00
Andrew Dupont
254440e6bc Oops 2024-01-11 15:07:11 -08:00
Andrew Dupont
4c6b0ba7d0 Ensure indentation decisions consult the correct layers…
…when straddling injection boundaries.
2024-01-11 15:07:11 -08:00
Andrew Dupont
c50b0e629f More PHP grammar feedback 2024-01-11 15:07:10 -08:00
Andrew Dupont
336f609f60 More PHP grammar feedback 2024-01-11 15:07:10 -08:00
Andrew Dupont
0b08306498 Don't add root scopes to CSS for TODO/hyperlink injections 2024-01-11 15:07:10 -08:00
Andrew Dupont
8836be7e16 Only inject TODO and hyperlink into CSS when needed 2024-01-11 15:07:10 -08:00
Andrew Dupont
2580642c0f Address feedback on PHP syntax highlighting 2024-01-11 15:07:10 -08:00
Andrew Dupont
f2dabe5167 Update tree-sitter-php WASM file to latest master 2024-01-11 15:07:10 -08:00
Andrew Dupont
8c946a004e [tree-sitter] TS: Treat parameters with defaults like parameters…
…plus a few other TypeScript fixes.
2024-01-11 15:07:10 -08:00
Andrew Dupont
58b9cc1865 Handle nowdocs in PHP 2024-01-11 15:07:10 -08:00
Andrew Dupont
ad8a215c77 Remove logging from injection callback 2024-01-11 15:07:09 -08:00
Andrew Dupont
c93bdeb21a Add parserSource fields where appropriate 2024-01-11 15:07:09 -08:00
Andrew Dupont
d148a73631 Add a modern Tree-sitter PHP grammar
This one’s got all the frills, including injections into HTML documents and a PHPDoc grammar.

As part of this change, we're also migrating to `web-tree-sitter` version 0.20.8 with some customizations. The PR I submitted at https://github.com/tree-sitter/tree-sitter/pull/2795 is landed on this fork, though if the same issues get fixed in a different way on the source, I'll adopt that approach as well. The PHPDoc parser needed another external added.
2024-01-11 15:07:09 -08:00
Andrew Dupont
b7dc65466f [tree-sitter] Fixes for shell script highlighting 2024-01-11 15:07:09 -08:00
Andrew Dupont
aef7c845b5 (oops) 2024-01-11 15:07:09 -08:00
Andrew Dupont
0b51a77cd6 [tree-sitter] Further JSX indent fixes for JS and TS alike 2024-01-11 15:07:09 -08:00