Skip to content

Commit fd908ca

Browse files
Merge pull request #829 from savetheclocktower/integrate-symbols-view-redux
Overhaul `symbols-view` (now a builtin package with data providers)
2 parents 69e4224 + 21441e0 commit fd908ca

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

78 files changed

+10586
-3
lines changed

.github/workflows/package-tests-linux.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,9 @@ jobs:
116116
- package: "spell-check"
117117
- package: "status-bar"
118118
- package: "styleguide"
119-
# - package: "symbols-view"
119+
- package: "symbol-provider-ctags"
120+
- package: "symbol-provider-tree-sitter"
121+
- package: "symbols-view"
120122
- package: "tabs"
121123
- package: "timecop"
122124
- package: "tree-view"

package.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,9 @@
166166
"status-bar": "file:packages/status-bar",
167167
"styleguide": "file:./packages/styleguide",
168168
"superstring": "^2.4.4",
169-
"symbols-view": "https://codeload.github.com/atom/symbols-view/legacy.tar.gz/refs/tags/v0.118.4",
169+
"symbol-provider-ctags": "file:./packages/symbol-provider-ctags",
170+
"symbol-provider-tree-sitter": "file:./packages/symbol-provider-tree-sitter",
171+
"symbols-view": "file:./packages/symbols-view",
170172
"tabs": "file:packages/tabs",
171173
"temp": "0.9.4",
172174
"text-buffer": "^13.18.6",
@@ -237,7 +239,9 @@
237239
"spell-check": "file:./packages/spell-check",
238240
"status-bar": "file:./packages/status-bar",
239241
"styleguide": "file:./packages/styleguide",
240-
"symbols-view": "0.118.4",
242+
"symbol-provider-ctags": "file:./packages/symbol-provider-ctags",
243+
"symbol-provider-tree-sitter": "file:./packages/symbol-provider-tree-sitter",
244+
"symbols-view": "file:./packages/symbols-view",
241245
"tabs": "file:./packages/tabs",
242246
"timecop": "file:./packages/timecop",
243247
"tree-view": "file:./packages/tree-view",
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
module.exports = {
2+
env: {
3+
browser: true,
4+
commonjs: true,
5+
es2021: true,
6+
},
7+
extends: [
8+
"eslint:recommended",
9+
"plugin:node/recommended",
10+
],
11+
overrides: [],
12+
parserOptions: {
13+
ecmaVersion: "latest"
14+
},
15+
rules: {
16+
"no-fallthrough": "off",
17+
"no-case-declarations": "off",
18+
"space-before-function-paren": ["error", {
19+
anonymous: "always",
20+
asyncArrow: "always",
21+
named: "never"
22+
}],
23+
"node/no-unpublished-require": [
24+
"error",
25+
{
26+
allowModules: ["electron"]
27+
}
28+
],
29+
"node/no-missing-require": [
30+
"error",
31+
{
32+
allowModules: ["atom"]
33+
}
34+
]
35+
},
36+
plugins: [
37+
"jsdoc"
38+
],
39+
globals: {
40+
atom: "writeable"
41+
}
42+
};
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
Copyright (c) 2023 Pulsar-Edit
2+
Original work copyright (c) 2011-2022 GitHub Inc.
3+
4+
Permission is hereby granted, free of charge, to any person obtaining
5+
a copy of this software and associated documentation files (the
6+
"Software"), to deal in the Software without restriction, including
7+
without limitation the rights to use, copy, modify, merge, publish,
8+
distribute, sublicense, and/or sell copies of the Software, and to
9+
permit persons to whom the Software is furnished to do so, subject to
10+
the following conditions:
11+
12+
The above copyright notice and this permission notice shall be
13+
included in all copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
18+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
19+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
20+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
21+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# symbol-provider-ctags package
2+
3+
Provides symbols to `symbols-view` via `ctags`.
4+
5+
This is the approach historically used by `symbols-view` — now spun out into its own “provider” package among several.
6+
7+
This symbol provider will typically be used on non-Tree-sitter grammars, and possibly when performing a project-wide search. Symbol-based navigation on files with Tree-sitter grammars will typically be provided by `symbol-provider-tree-sitter`.
8+
9+
## Language support
10+
11+
This provider supports any language that is present in its config file, and detects any symbols that match the specified patterns. If your language isn’t supported and you can help add support, we’ll happily accept a pull request.
12+
13+
## Toggle file symbols
14+
15+
For the **Symbols View: Toggle File Symbols** command, `ctags` will scan the file on disk and emit its tag information to stdout, where it is read by this package. You don’t need a `TAGS` file to do a symbol search within a single file.
16+
17+
## Toggle Project Symbols, Go To Declaration
18+
19+
These commands require a tags file, typically defined at `.tags`/`tags`/`.TAGS`/`TAGS` in the root of your project. This package cannot generate (or regenerate) your tags file, since it doesn’t know which files to include. You can run `ctags` regularly on your own to generate this file. Consult [the documentation for Exuberant Ctags](https://ctags.sourceforge.net/ctags.html) for more information.
20+
21+
Once your tags file is present, these commands can be fulfilled by `symbol-provider-ctags`
22+
23+
* The **Symbols View: Toggle Project Symbols** command works like **Symbols View: Toggle File Symbols** described above, except it’ll show you symbols from the entire project.
24+
* The **Symbols View: Go To Declaration** command works like **Symbols View: Toggle Project Symbols**, except the word under the cursor will be pre-filled in the search box, and a result will automatically be opened if it is the only result.
Lines changed: 222 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,222 @@
1+
--langdef=CoffeeScript
2+
--langmap=CoffeeScript:.coffee
3+
--regex-CoffeeScript=/^[ \t]*(@?[a-zA-Z$_\.0-9]+)[ \t]*(=|\:)[ \t]*(\(.*\))?[ \t]*(-|=)>/\1/f,function/
4+
--regex-CoffeeScript=/^[ \t]*([a-zA-Z$_0-9]+\:\:[a-zA-Z$_\.0-9]+)[ \t]*(=|\:)[ \t]*(\(.*\))?[ \t]*(-|=)>/\1/f,function/
5+
--regex-CoffeeScript=/^[ \t]*describe[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
6+
--regex-CoffeeScript=/^[ \t]*describe[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
7+
--regex-CoffeeScript=/^[ \t]*it[ \t]"([^"]+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
8+
--regex-CoffeeScript=/^[ \t]*it[ \t]'([^']+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
9+
--regex-CoffeeScript=/^[ \t]*f+describe[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/focused\: \1/f,function/
10+
--regex-CoffeeScript=/^[ \t]*f+describe[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/focused: \1/f,function/
11+
--regex-CoffeeScript=/^[ \t]*f+it[ \t]"([^"]+)"[ \t]*,[ \t]+[-=]>/focused: \1/f,function/
12+
--regex-CoffeeScript=/^[ \t]*f+it[ \t]'([^']+)'[ \t]*,[ \t]+[-=]>/focused: \1/f,function/
13+
--regex-CoffeeScript=/^[ \t]*xdescribe[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/disabled\: \1/f,function/
14+
--regex-CoffeeScript=/^[ \t]*xdescribe[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/disabled: \1/f,function/
15+
--regex-CoffeeScript=/^[ \t]*xit[ \t]"([^"]+)"[ \t]*,[ \t]+[-=]>/disabled: \1/f,function/
16+
--regex-CoffeeScript=/^[ \t]*xit[ \t]'([^']+)'[ \t]*,[ \t]+[-=]>/disabled: \1/f,function/
17+
--regex-CoffeeScript=/^[ \t]*class[ \t]*([a-zA-Z$_\.0-9]+)[ \t]*/\1/f,function/
18+
19+
--langdef=ColdFusion
20+
--langmap=ColdFusion:.cfc
21+
--langmap=ColdFusion:+.cfm
22+
--langmap=ColdFusion:+.cfml
23+
--regex-ColdFusion=/(,|(;|^)[ \t]*(var|([A-Za-z_$][A-Za-z0-9_$.]*\.)*))[ \t]*([A-Za-z0-9_$]+)[ \t]*=[ \t]*function[ \t]*\(/\5/,function/
24+
--regex-ColdFusion=/function[ \t]+([A-Za-z0-9_$]+)[ \t]*\([^)]*\)/\1/,function/
25+
--regex-ColdFusion=/cffunction[ \t]+([A-Za-z0-9_$]+)[ \t]*\([^)]*\)/\1/,cffunction/
26+
--regex-ColdFusion=/(,|^|\*\/)[ \t]*([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*:[ \t]*function[ \t]*\(/\2/,function/
27+
--regex-ColdFusion=/(,|^|\*\/)[ \t]*(static[ \t]+)?(while|if|for|function|switch|with|([A-Za-z_$][A-Za-z0-9_$]+))[ \t]*\(.*\)[ \t]*\{/\2\4/,function/
28+
--regex-ColdFusion=/(,|^|\*\/)[ \t]*get[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*\)[ \t]*\{/get \2/,function/
29+
--regex-ColdFusion=/(,|^|\*\/)[ \t]*set[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*([A-Za-z_$][A-Za-z0-9_$]+)?[ \t]*\)[ \t]*\{/set \2/,function/
30+
--regex-ColdFusion=/(,|^|\*\/)[ \t]*async[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*([A-Za-z_$].+)?[ \t]*\)[ \t]*\{/\2/,function/
31+
--regex-ColdFusion=/component[ \t]+([A-Za-z0-9._$]+)[ \t]*/\1/c,component/
32+
--regex-ColdFusion=/^[ \t]*given[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
33+
--regex-ColdFusion=/^[ \t]*given[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
34+
--regex-ColdFusion=/^[ \t]*story[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
35+
--regex-ColdFusion=/^[ \t]*story[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
36+
--regex-ColdFusion=/^[ \t]*feature[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
37+
--regex-ColdFusion=/^[ \t]*feature[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
38+
--regex-ColdFusion=/^[ \t]*when[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
39+
--regex-ColdFusion=/^[ \t]*when[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
40+
--regex-ColdFusion=/^[ \t]*then[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
41+
--regex-ColdFusion=/^[ \t]*then[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
42+
--regex-ColdFusion=/^[ \t]*describe[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
43+
--regex-ColdFusion=/^[ \t]*describe[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
44+
--regex-ColdFusion=/^[ \t]*it[ \t]"([^"]+)"[ \t]*,[ \t]+[-=]>/\1/f,function/
45+
--regex-ColdFusion=/^[ \t]*it[ \t]'([^']+)'[ \t]*,[ \t]+[-=]>/\1/f,function/
46+
--regex-ColdFusion=/^[ \t]*xdescribe[ \t]"(.+)"[ \t]*,[ \t]+[-=]>/disabled\: \1/f,function/
47+
--regex-ColdFusion=/^[ \t]*xdescribe[ \t]'(.+)'[ \t]*,[ \t]+[-=]>/disabled: \1/f,function/
48+
--regex-ColdFusion=/^[ \t]*xit[ \t]"([^"]+)"[ \t]*,[ \t]+[-=]>/disabled: \1/f,function/
49+
--regex-ColdFusion=/^[ \t]*xit[ \t]'([^']+)'[ \t]*,[ \t]+[-=]>/disabled: \1/f,function/
50+
51+
--langdef=Css
52+
--langmap=Css:.css
53+
--langmap=Css:+.less
54+
--langmap=Css:+.scss
55+
--regex-Css=/^[ \t]*(.+)[ \t]*\{/\1/f,function/
56+
--regex-Css=/^[ \t]*(.+)[ \t]*,[ \t]*$/\1/f,function/
57+
--regex-Css=/^[ \t]*[@$]([a-zA-Z$_][-a-zA-Z$_0-9]*)[ \t]*:/\1/f,function/
58+
59+
--langdef=Sass
60+
--langmap=Sass:.sass
61+
--regex-Sass=/^[ \t]*([#.]*[a-zA-Z_0-9]+)[ \t]*$/\1/f,function/
62+
63+
--langdef=Yaml
64+
--langmap=Yaml:.yaml
65+
--langmap=Yaml:+.yml
66+
--regex-Yaml=/^[ \t]*([a-zA-Z_0-9 ]+)[ \t]*\:[ \t]*/\1/f,function/
67+
68+
--regex-Html=/^[ \t]*<([a-zA-Z]+)[ \t]*.*>/\1/f,function/
69+
70+
--langdef=Markdown
71+
--langmap=Markdown:.md
72+
--langmap=Markdown:+.markdown
73+
--langmap=Markdown:+.mdown
74+
--langmap=Markdown:+.mkd
75+
--langmap=Markdown:+.mkdown
76+
--langmap=Markdown:+.ron
77+
--regex-Markdown=/^#+[ \t]*([^#]+)/\1/f,function/
78+
79+
--langdef=Json
80+
--langmap=Json:.json
81+
--regex-Json=/^[ \t]*"([^"]+)"[ \t]*\:/\1/f,function/
82+
83+
--langdef=Cson
84+
--langmap=Cson:.cson
85+
--langmap=Cson:+.gyp
86+
--regex-Cson=/^[ \t]*'([^']+)'[ \t]*\:/\1/f,function/
87+
--regex-Cson=/^[ \t]*"([^"]+)"[ \t]*\:/\1/f,function/
88+
--regex-Cson=/^[ \t]*([^'"]+)[ \t]*\:/\1/f,function/
89+
90+
--langmap=C++:+.mm
91+
92+
--langmap=Ruby:+(Rakefile)
93+
94+
--langmap=Php:+.module
95+
96+
--langdef=Go
97+
--langmap=Go:.go
98+
--regex-Go=/func([ \t]+\([^)]+\))?[ \t]+([a-zA-Z0-9_]+)/\2/f,func/
99+
--regex-Go=/var[ \t]+([a-zA-Z_][a-zA-Z0-9_]*)/\1/v,var/
100+
--regex-Go=/type[ \t]+([a-zA-Z_][a-zA-Z0-9_]*)/\1/t,type/
101+
102+
--langdef=Capnp
103+
--langmap=Capnp:.capnp
104+
--regex-Capnp=/struct[ \t]+([A-Za-z]+)/\1/s,struct/
105+
--regex-Capnp=/enum[ \t]+([A-Za-z]+)/\1/e,enum/
106+
--regex-Capnp=/using[ \t]+([A-Za-z]+)[ \t]+=[ \t]+import/\1/u,using/
107+
--regex-Capnp=/const[ \t]+([A-Za-z]+)/\1/c,const/
108+
109+
--langmap=perl:+.pod
110+
--regex-perl=/with[ \t]+([^;]+)[ \t]*?;/\1/w,role,roles/
111+
--regex-perl=/extends[ \t]+['"]([^'"]+)['"][ \t]*?;/\1/e,extends/
112+
--regex-perl=/use[ \t]+base[ \t]+['"]([^'"]+)['"][ \t]*?;/\1/e,extends/
113+
--regex-perl=/use[ \t]+parent[ \t]+['"]([^'"]+)['"][ \t]*?;/\1/e,extends/
114+
--regex-perl=/Mojo::Base[ \t]+['"]([^'"]+)['"][ \t]*?;/\1/e,extends/
115+
--regex-perl=/^[ \t]*?use[ \t]+([^;]+)[ \t]*?;/\1/u,use,uses/
116+
--regex-perl=/^[ \t]*?require[ \t]+((\w|\:)+)/\1/r,require,requires/
117+
--regex-perl=/^[ \t]*?has[ \t]+['"]?(\w+)['"]?/\1/a,attribute,attributes/
118+
--regex-perl=/^[ \t]*?\*(\w+)[ \t]*?=/\1/a,alias,aliases/
119+
--regex-perl=/->helper\([ \t]?['"]?(\w+)['"]?/\1/h,helper,helpers/
120+
--regex-perl=/^[ \t]*?our[ \t]*?[\$@%](\w+)/\1/o,our,ours/
121+
--regex-perl=/^\=head1[ \t]+(.+)/\1/p,pod,Plain Old Documentation/
122+
--regex-perl=/^\=head2[ \t]+(.+)/-- \1/p,pod,Plain Old Documentation/
123+
--regex-perl=/^\=head[3-5][ \t]+(.+)/---- \1/p,pod,Plain Old Documentation/
124+
125+
--regex-JavaScript=/(,|(;|^)[ \t]*(var|let|([A-Za-z_$][A-Za-z0-9_$.]*\.)*))[ \t]*([A-Za-z0-9_$]+)[ \t]*=[ \t]*function[ \t]*\(/\5/,function/
126+
--regex-JavaScript=/function[ \t]+([A-Za-z0-9_$]+)[ \t]*\([^)]*\)/\1/,function/
127+
--regex-JavaScript=/(,|^|\*\/)[ \t]*([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*:[ \t]*function[ \t]*\(/\2/,function/
128+
--regex-JavaScript=/(,|^|\*\/)[ \t]*(static[ \t]+)?(while|if|for|function|switch|with|([A-Za-z_$][A-Za-z0-9_$]+))[ \t]*\(.*\)[ \t]*\{/\2\4/,function/
129+
--regex-JavaScript=/(,|^|\*\/)[ \t]*get[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*\)[ \t]*\{/get \2/,function/
130+
--regex-JavaScript=/(,|^|\*\/)[ \t]*set[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*([A-Za-z_$][A-Za-z0-9_$]+)?[ \t]*\)[ \t]*\{/set \2/,function/
131+
--regex-JavaScript=/(,|^|\*\/)[ \t]*async[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*([A-Za-z_$].+)?[ \t]*\)[ \t]*\{/\2/,function/
132+
--regex-JavaScript=/class[ \t]+([A-Za-z0-9._$]+)[ \t]*/\1/c,class/
133+
--regex-JavaScript=/^[ \t]*describe\("([^"]+)"[ \t]*,/\1/f,function/
134+
--regex-JavaScript=/^[ \t]*describe\('([^']+)'[ \t]*,/\1/f,function/
135+
--regex-JavaScript=/^[ \t]*it\("([^"]+)"[ \t]*,/\1/f,function/
136+
--regex-JavaScript=/^[ \t]*it\('([^']+)'[ \t]*,/\1/f,function/
137+
--regex-JavaScript=/^[ \t]*f+describe\('([^']+)'[ \t]*,/focused: \1/f,function/
138+
--regex-JavaScript=/^[ \t]*f+describe\("([^"]+)"[ \t]*,/focused: \1/f,function/
139+
--regex-JavaScript=/^[ \t]*f+it\('([^']+)'[ \t]*,/focused: \1/f,function/
140+
--regex-JavaScript=/^[ \t]*f+it\("([^"]+)"[ \t]*,/focused: \1/f,function/
141+
--regex-JavaScript=/^[ \t]*xdescribe\('([^']+)'[ \t]*,/disabled: \1/f,function/
142+
--regex-JavaScript=/^[ \t]*xdescribe\("([^"]+)"[ \t]*,/disabled: \1/f,function/
143+
--regex-JavaScript=/^[ \t]*xit\('([^']+)'[ \t]*,/disabled: \1/f,function/
144+
--regex-JavaScript=/^[ \t]*xit\("([^"]+)"[ \t]*,/disabled: \1/f,function/
145+
146+
--langdef=TypeScript
147+
--langmap=TypeScript:.ts
148+
--langmap=TypeScript:+.tsx
149+
--regex-TypeScript=/(,|(;|^)[ \t]*(var|let|([A-Za-z_$][A-Za-z0-9_$.]*\.)*))[ \t]*([A-Za-z0-9_$]+)[ \t]*=[ \t]*function[ \t]*\(/\5/,function/
150+
--regex-TypeScript=/function[ \t]+([A-Za-z0-9_$]+)[ \t]*\([^)]*\)/\1/,function/
151+
--regex-TypeScript=/(,|^|\*\/)[ \t]*([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*:[ \t]*function[ \t]*\(/\2/,function/
152+
--regex-TypeScript=/(,|^|\*\/)[ \t]*(static[ \t]+)?(while|if|for|function|switch|with|([A-Za-z_$][A-Za-z0-9_$]+))[ \t]*\(.*\)[ \t]*\{/\2\4/,function/
153+
--regex-TypeScript=/(,|^|\*\/)[ \t]*get[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*\)[ \t]*\{/get \2/,function/
154+
--regex-TypeScript=/(,|^|\*\/)[ \t]*set[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*([A-Za-z_$][A-Za-z0-9_$]+)?[ \t]*\)[ \t]*\{/set \2/,function/
155+
--regex-TypeScript=/(,|^|\*\/)[ \t]*async[ \t]+([A-Za-z_$][A-Za-z0-9_$]+)[ \t]*\([ \t]*([A-Za-z_$].+)?[ \t]*\)[ \t]*\{/\2/,function/
156+
--regex-TypeScript=/class[ \t]+([A-Za-z0-9._$]+)[ \t]*/\1/c,class/
157+
--regex-TypeScript=/^[ \t]*describe\("([^"]+)"[ \t]*,/\1/f,function/
158+
--regex-TypeScript=/^[ \t]*describe\('([^']+)'[ \t]*,/\1/f,function/
159+
--regex-TypeScript=/^[ \t]*it\("([^"]+)"[ \t]*,/\1/f,function/
160+
--regex-TypeScript=/^[ \t]*it\('([^']+)'[ \t]*,/\1/f,function/
161+
--regex-TypeScript=/^[ \t]*f+describe\('([^']+)'[ \t]*,/focused: \1/f,function/
162+
--regex-TypeScript=/^[ \t]*f+describe\("([^"]+)"[ \t]*,/focused: \1/f,function/
163+
--regex-TypeScript=/^[ \t]*f+it\('([^']+)'[ \t]*,/focused: \1/f,function/
164+
--regex-TypeScript=/^[ \t]*f+it\("([^"]+)"[ \t]*,/focused: \1/f,function/
165+
--regex-TypeScript=/^[ \t]*xdescribe\('([^']+)'[ \t]*,/disabled: \1/f,function/
166+
--regex-TypeScript=/^[ \t]*xdescribe\("([^"]+)"[ \t]*,/disabled: \1/f,function/
167+
--regex-TypeScript=/^[ \t]*xit\('([^']+)'[ \t]*,/disabled: \1/f,function/
168+
--regex-TypeScript=/^[ \t]*xit\("([^"]+)"[ \t]*,/disabled: \1/f,function/
169+
170+
--langdef=haxe
171+
--langmap=haxe:.hx
172+
--regex-haxe=/^package[ \t]+([A-Za-z0-9_.]+)/\1/p,package/
173+
--regex-haxe=/^[ \t]*[(@:macro|private|public|static|override|inline|dynamic)( \t)]*function[ \t]+([A-Za-z0-9_]+)/\1/f,function/
174+
--regex-haxe=/^[ \t]*([private|public|static|protected|inline][ \t]*)+var[ \t]+([A-Za-z0-9_]+)/\2/v,variable/
175+
--regex-haxe=/^[ \t]*package[ \t]*([A-Za-z0-9_]+)/\1/p,package/
176+
--regex-haxe=/^[ \t]*(extern[ \t]*|@:native\([^)]*\)[ \t]*)*class[ \t]+([A-Za-z0-9_]+)[ \t]*[^\{]*/\2/c,class/
177+
--regex-haxe=/^[ \t]*(extern[ \t]+)?interface[ \t]+([A-Za-z0-9_]+)/\2/i,interface/
178+
--regex-haxe=/^[ \t]*typedef[ \t]+([A-Za-z0-9_]+)/\1/t,typedef/
179+
--regex-haxe=/^[ \t]*enum[ \t]+([A-Za-z0-9_]+)/\1/t,typedef/
180+
--regex-haxe=/^[ \t]*+([A-Za-z0-9_]+)(;|\([^)]*:[^)]*\))/\1/t,enum_field/
181+
182+
--langdef=Elixir
183+
--langmap=Elixir:.ex.exs
184+
--regex-Elixir=/^[ \t]*def(p?)[ \t]+([a-z_][a-zA-Z0-9_?!]*)/\2/f,functions,functions (def ...)/
185+
--regex-Elixir=/^[ \t]*defcallback[ \t]+([a-z_][a-zA-Z0-9_?!]*)/\1/c,callbacks,callbacks (defcallback ...)/
186+
--regex-Elixir=/^[ \t]*defdelegate[ \t]+([a-z_][a-zA-Z0-9_?!]*)/\1/d,delegates,delegates (defdelegate ...)/
187+
--regex-Elixir=/^[ \t]*defexception[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/e,exceptions,exceptions (defexception ...)/
188+
--regex-Elixir=/^[ \t]*defimpl[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/i,implementations,implementations (defimpl ...)/
189+
--regex-Elixir=/^[ \t]*defmacro(p?)[ \t]+([a-z_][a-zA-Z0-9_?!]*)\(/\2/a,macros,macros (defmacro ...)/
190+
--regex-Elixir=/^[ \t]*defmacro(p?)[ \t]+([a-zA-Z0-9_?!]+)?[ \t]+([^ \tA-Za-z0-9_]+)[ \t]*[a-zA-Z0-9_!?!]/\3/o,operators,operators (e.g. "defmacro a <<< b")/
191+
--regex-Elixir=/^[ \t]*defmodule[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/m,modules,modules (defmodule ...)/
192+
--regex-Elixir=/^[ \t]*defprotocol[ \t]+([A-Z][a-zA-Z0-9_]*\.)*([A-Z][a-zA-Z0-9_?!]*)/\2/p,protocols,protocols (defprotocol...)/
193+
--regex-Elixir=/^[ \t]*Record\.defrecord[ \t]+:([a-zA-Z0-9_]+)/\1/r,records,records (defrecord...)/
194+
195+
--langdef=Nim
196+
--langmap=Nim:.nim
197+
--regex-Nim=/^[\t\s]*proc\s+([_A-Za-z0-9]+)\**(\[\w+(\:\s+\w+)?\])?\s*\(/\1/f,function/
198+
--regex-Nim=/^[\t\s]*iterator\s+([_A-Za-z0-9]+)\**(\[\w+(\:\s+\w+)?\])?\s*\(/\1/i,iterator/
199+
--regex-Nim=/^[\t\s]*macro\s+([_A-Za-z0-9]+)\**(\[\w+(\:\s+\w+)?\])?\s*\(/\1/m,macro/
200+
--regex-Nim=/^[\t\s]*method\s+([_A-Za-z0-9]+)\**(\[\w+(\:\s+\w+)?\])?\s*\(/\1/h,method/
201+
--regex-Nim=/^[\t\s]*template\s+([_A-Za-z0-9]+)\**(\[\w+(\:\s+\w+)?\])?\s*\(/\1/t,generics/
202+
--regex-Nim=/^[\t\s]*converter\s+([_A-Za-z0-9]+)\**(\[\w+(\:\s+\w+)?\])?\s*\(/\1/c,converter/
203+
204+
--langdef=Fountain
205+
--langmap=Fountain:.fountain
206+
--langmap=Fountain:+.ftn
207+
--regex-Fountain=/^(([iI][nN][tT]|[eE][xX][tT]|[^\w][eE][sS][tT]|\.|[iI]\.?\/[eE]\.?)([^\n]+))/\1/f,function/
208+
209+
--langdef=Julia
210+
--langmap=Julia:.jl
211+
--regex-Julia=/^[ \t]*(function|macro|abstract|type|typealias|immutable)[ \t]+([^ \t({[]+).*$/\2/f,function/
212+
--regex-Julia=/^[ \t]*(([^@#$ \t({[]+)|\(([^@#$ \t({[]+)\)|\((\$)\))[ \t]*(\{.*\})?[ \t]*\([^#]*\)[ \t]*=([^=].*$|$)/\2\3\4/f,function/
213+
214+
--langdef=Latex
215+
--langmap=latex:.tex
216+
--regex-latex=/\\label\{([^}]*)\}/\1/l,label/
217+
--regex-latex=/\\section\{([^}]*)\}/\1/s,section/
218+
--regex-latex=/\\subsection\{([^}]*)\}/\1/t,subsection/
219+
--regex-latex=/\\subsubsection\{([^}]*)\}/\1/u,subsubsection/
220+
--regex-latex=/\\section\*\{([^}]*)\}/\1/s,section/
221+
--regex-latex=/\\subsection\*\{([^}]*)\}/\1/t,subsection/
222+
--regex-latex=/\\subsubsection\*\{([^}]*)\}/\1/u,subsubsection/

0 commit comments

Comments
 (0)