@ohos-npm-ports/ast-grep-napi 0.43.0-1 → 0.43.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.txt +2 -0
- package/package.json +7 -82
- package/LICENSE +0 -21
- package/README.md +0 -34
- package/ast-grep-napi.openharmony-arm64.node +0 -0
- package/index.d.ts +0 -14
- package/index.js +0 -594
- package/lang/Css.d.ts +0 -2181
- package/lang/Html.d.ts +0 -283
- package/lang/JavaScript.d.ts +0 -2932
- package/lang/Tsx.d.ts +0 -5470
- package/lang/TypeScript.d.ts +0 -5228
- package/types/api.d.ts +0 -46
- package/types/config.d.ts +0 -39
- package/types/deprecated.d.ts +0 -117
- package/types/lang.d.ts +0 -11
- package/types/registerDynamicLang.d.ts +0 -27
- package/types/rule.d.ts +0 -105
- package/types/sgnode.d.ts +0 -126
- package/types/staticTypes.d.ts +0 -102
package/README.txt
ADDED
package/package.json
CHANGED
|
@@ -1,84 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ohos-npm-ports/ast-grep-napi",
|
|
3
|
-
"version": "0.43.0-1",
|
|
4
|
-
"description": "
|
|
5
|
-
"
|
|
6
|
-
"
|
|
7
|
-
"
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
"directory": "ports/ast-grep-napi/0.43.0"
|
|
11
|
-
},
|
|
12
|
-
"license": "MIT",
|
|
13
|
-
"keywords": [
|
|
14
|
-
"ast",
|
|
15
|
-
"pattern",
|
|
16
|
-
"codemod",
|
|
17
|
-
"search",
|
|
18
|
-
"rewrite"
|
|
19
|
-
],
|
|
20
|
-
"files": [
|
|
21
|
-
"index.d.ts",
|
|
22
|
-
"index.js",
|
|
23
|
-
"types/*.ts",
|
|
24
|
-
"lang/*.ts",
|
|
25
|
-
"ast-grep-napi.openharmony-arm64.node"
|
|
26
|
-
],
|
|
27
|
-
"napi": {
|
|
28
|
-
"binaryName": "ast-grep-napi",
|
|
29
|
-
"targets": [
|
|
30
|
-
"x86_64-unknown-linux-gnu",
|
|
31
|
-
"x86_64-pc-windows-msvc",
|
|
32
|
-
"x86_64-apple-darwin",
|
|
33
|
-
"i686-pc-windows-msvc",
|
|
34
|
-
"aarch64-apple-darwin",
|
|
35
|
-
"aarch64-pc-windows-msvc",
|
|
36
|
-
"aarch64-unknown-linux-gnu",
|
|
37
|
-
"aarch64-unknown-linux-musl",
|
|
38
|
-
"x64-unknown-linux-musl"
|
|
39
|
-
]
|
|
40
|
-
},
|
|
41
|
-
"engines": {
|
|
42
|
-
"node": ">= 10"
|
|
43
|
-
},
|
|
44
|
-
"publishConfig": {
|
|
45
|
-
"registry": "https://registry.npmjs.org/",
|
|
46
|
-
"access": "public"
|
|
47
|
-
},
|
|
48
|
-
"devDependencies": {
|
|
49
|
-
"@ast-grep/napi": "0.42.3",
|
|
50
|
-
"@napi-rs/cli": "3.6.2",
|
|
51
|
-
"@types/node": "^24.0.0",
|
|
52
|
-
"oxlint": "1.66.0",
|
|
53
|
-
"ava": "7.0.0",
|
|
54
|
-
"chalk": "5.6.2",
|
|
55
|
-
"dprint": "0.54.0",
|
|
56
|
-
"smol-toml": "^1.3.1",
|
|
57
|
-
"tsimp": "2.0.12",
|
|
58
|
-
"typescript": "6.0.3"
|
|
59
|
-
},
|
|
60
|
-
"ava": {
|
|
61
|
-
"nodeArguments": [
|
|
62
|
-
"--import=tsimp"
|
|
63
|
-
],
|
|
64
|
-
"extensions": {
|
|
65
|
-
"ts": "module"
|
|
66
|
-
},
|
|
67
|
-
"timeout": "2m",
|
|
68
|
-
"workerThreads": false,
|
|
69
|
-
"environmentVariables": {
|
|
70
|
-
"TS_NODE_PROJECT": "./tsconfig.json"
|
|
71
|
-
}
|
|
72
|
-
},
|
|
73
|
-
"optionalDependencies": {
|
|
74
|
-
"@ast-grep/napi-linux-x64-gnu": "0.43.0",
|
|
75
|
-
"@ast-grep/napi-win32-x64-msvc": "0.43.0",
|
|
76
|
-
"@ast-grep/napi-darwin-x64": "0.43.0",
|
|
77
|
-
"@ast-grep/napi-win32-ia32-msvc": "0.43.0",
|
|
78
|
-
"@ast-grep/napi-darwin-arm64": "0.43.0",
|
|
79
|
-
"@ast-grep/napi-win32-arm64-msvc": "0.43.0",
|
|
80
|
-
"@ast-grep/napi-linux-arm64-gnu": "0.43.0",
|
|
81
|
-
"@ast-grep/napi-linux-arm64-musl": "0.43.0",
|
|
82
|
-
"@ast-grep/napi-linux-x64-musl": "0.43.0"
|
|
83
|
-
}
|
|
84
|
-
}
|
|
3
|
+
"version": "0.43.0-beta.1",
|
|
4
|
+
"description": "Empty placeholder package.",
|
|
5
|
+
"main": "README.txt",
|
|
6
|
+
"files": ["README.txt"],
|
|
7
|
+
"keywords": ["empty", "placeholder"],
|
|
8
|
+
"license": "MIT"
|
|
9
|
+
}
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2020 N-API for Rust
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
package/README.md
DELETED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
# @ast-grep/napi
|
|
2
|
-
|
|
3
|
-
<p align=center>
|
|
4
|
-
<img src="https://ast-grep.github.io/logo.svg" alt="ast-grep"/>
|
|
5
|
-
</p>
|
|
6
|
-
|
|
7
|
-
## ast-grep(sg)
|
|
8
|
-
|
|
9
|
-
ast-grep(sg) is a CLI tool for code structural search, lint, and rewriting.
|
|
10
|
-
|
|
11
|
-
This npm package is for programmatic usage of ast-grep.
|
|
12
|
-
Please see the [API usage guide](https://ast-grep.github.io/guide/api-usage.html) and [API reference](https://ast-grep.github.io/reference/api.html).
|
|
13
|
-
|
|
14
|
-
Other resources include [ast-grep's official site](https://ast-grep.github.io/) and [repository](https://github.com/ast-grep/ast-grep).
|
|
15
|
-
|
|
16
|
-
## Support matrix
|
|
17
|
-
|
|
18
|
-
### Operating Systems
|
|
19
|
-
|
|
20
|
-
| | node14 | node16 | node18 |
|
|
21
|
-
| ---------------- | ------ | ------ | ------ |
|
|
22
|
-
| Windows x64 | ✓ | ✓ | ✓ |
|
|
23
|
-
| macOS x64 | ✓ | ✓ | ✓ |
|
|
24
|
-
| macOS arm64 | ✓ | ✓ | ✓ |
|
|
25
|
-
| Linux x64 gnu | ✓ | ✓ | ✓ |
|
|
26
|
-
| Windows x32 | ✓ | ✓ | ✓ |
|
|
27
|
-
| Windows arm64 | ✓ | ✓ | ✓ |
|
|
28
|
-
<!-- | Linux arm gnu | ✓ | ✓ | ✓ | -->
|
|
29
|
-
<!-- | Linux x64 musl | ✓ | ✓ | ✓ | -->
|
|
30
|
-
<!-- | Linux arm64 gnu | ✓ | ✓ | ✓ | -->
|
|
31
|
-
<!-- | Linux arm64 musl | ✓ | ✓ | ✓ | -->
|
|
32
|
-
<!-- | Android arm64 | ✓ | ✓ | ✓ | -->
|
|
33
|
-
<!-- | Android armv7 | ✓ | ✓ | ✓ | -->
|
|
34
|
-
<!-- | FreeBSD x64 | ✓ | ✓ | ✓ | -->
|
|
Binary file
|
package/index.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
// -----Type Only Export!-----//
|
|
2
|
-
export type { FileOption, FindConfig, NapiConfig } from './types/config'
|
|
3
|
-
export type { DynamicLangRegistrations } from './types/registerDynamicLang'
|
|
4
|
-
export type { Edit, Pos, Range } from './types/sgnode'
|
|
5
|
-
// Only Rule here. User can use Rule['pattern'], e.g., to get the type of subfield.
|
|
6
|
-
export type { Rule } from './types/rule'
|
|
7
|
-
|
|
8
|
-
// -----Runtime Value Export!-----//
|
|
9
|
-
export { findInFiles, kind, parse, parseAsync, parseFiles, pattern } from './types/api'
|
|
10
|
-
export { Lang } from './types/lang'
|
|
11
|
-
export { registerDynamicLanguage } from './types/registerDynamicLang'
|
|
12
|
-
export { SgNode, SgRoot } from './types/sgnode'
|
|
13
|
-
// deprecated
|
|
14
|
-
export * from './types/deprecated'
|