immosquare-cleaner 0.1.43 → 0.1.44
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/immosquare-cleaner/version.rb +1 -1
- data/node_modules/@eslint/js/package.json +1 -1
- data/node_modules/eslint/README.md +1 -1
- data/node_modules/eslint/lib/cli.js +4 -3
- data/node_modules/eslint/lib/eslint/eslint.js +93 -17
- data/node_modules/eslint/lib/languages/js/source-code/source-code.js +1 -1
- data/node_modules/eslint/lib/rules/require-await.js +37 -3
- data/node_modules/eslint/lib/rules/utils/ast-utils.js +4 -3
- data/node_modules/eslint/lib/shared/flags.js +2 -1
- data/node_modules/eslint/package.json +17 -8
- data/node_modules/jscodeshift/CHANGELOG.md +17 -0
- data/node_modules/jscodeshift/CONTRIBUTING.md +7 -6
- data/node_modules/jscodeshift/README.md +3 -2
- data/node_modules/jscodeshift/dist/Runner.js +15 -15
- data/node_modules/jscodeshift/dist/collections/ImportDeclaration.js +113 -0
- data/node_modules/jscodeshift/dist/collections/index.js +1 -0
- data/node_modules/jscodeshift/dist/src/Runner.js +15 -15
- data/node_modules/jscodeshift/dist/src/collections/ImportDeclaration.js +113 -0
- data/node_modules/jscodeshift/dist/src/collections/index.js +1 -0
- data/node_modules/jscodeshift/package.json +9 -7
- data/node_modules/jscodeshift/parser/tsOptions.js +2 -0
- data/node_modules/jscodeshift/src/Runner.js +15 -15
- data/node_modules/jscodeshift/src/collections/ImportDeclaration.js +113 -0
- data/node_modules/jscodeshift/src/collections/index.js +1 -0
- data/node_modules/jscodeshift/utils/testUtils.js +1 -2
- data/node_modules/jscodeshift/website/README.md +44 -0
- data/node_modules/jscodeshift/website/astro.config.mjs +36 -0
- data/node_modules/jscodeshift/website/package.json +17 -0
- data/node_modules/jscodeshift/website/public/favicon.svg +1 -0
- data/node_modules/jscodeshift/website/src/assets/houston.webp +0 -0
- data/node_modules/jscodeshift/website/src/content/config.ts +6 -0
- data/node_modules/jscodeshift/website/src/content/docs/build/api-reference.mdx +406 -0
- data/node_modules/jscodeshift/website/src/content/docs/build/ast-grammar.mdx +3086 -0
- data/node_modules/jscodeshift/website/src/content/docs/index.mdx +15 -0
- data/node_modules/jscodeshift/website/src/content/docs/overview/introduction.mdx +45 -0
- data/node_modules/jscodeshift/website/src/content/docs/run/cli.mdx +161 -0
- data/node_modules/jscodeshift/website/src/env.d.ts +2 -0
- data/node_modules/jscodeshift/website/tsconfig.json +3 -0
- data/node_modules/npm-check-updates/README.md +34 -21
- data/node_modules/npm-check-updates/build/index.js +136 -136
- data/node_modules/npm-check-updates/build/index.js.map +1 -1
- data/node_modules/npm-check-updates/package.json +1 -1
- data/package.json +4 -4
- metadata +18 -10
- data/node_modules/jscodeshift/node_modules/chalk/index.d.ts +0 -415
- data/node_modules/jscodeshift/node_modules/chalk/license +0 -9
- data/node_modules/jscodeshift/node_modules/chalk/package.json +0 -68
- data/node_modules/jscodeshift/node_modules/chalk/readme.md +0 -341
- data/node_modules/jscodeshift/node_modules/chalk/source/index.js +0 -229
- data/node_modules/jscodeshift/node_modules/chalk/source/templates.js +0 -134
- data/node_modules/jscodeshift/node_modules/chalk/source/util.js +0 -39
- data/node_modules/jscodeshift/website/index.htm +0 -9
@@ -0,0 +1,15 @@
|
|
1
|
+
---
|
2
|
+
title: Docs
|
3
|
+
description: Get started with building and running jscodeshift codemods.
|
4
|
+
template: doc
|
5
|
+
hero:
|
6
|
+
tagline: Get started with building and running jscodeshift codemods.
|
7
|
+
actions:
|
8
|
+
- text: Get started
|
9
|
+
link: /overview/introduction/
|
10
|
+
icon: right-arrow
|
11
|
+
variant: primary
|
12
|
+
- text: GitHub
|
13
|
+
link: https://github.com/facebook/jscodeshift
|
14
|
+
icon: external
|
15
|
+
---
|
@@ -0,0 +1,45 @@
|
|
1
|
+
---
|
2
|
+
title: Introduction
|
3
|
+
---
|
4
|
+
|
5
|
+
import { Steps, LinkCard, Card, CardGrid } from '@astrojs/starlight/components';
|
6
|
+
|
7
|
+
`jscodeshift` is a toolkit for building and running codemods over multiple JavaScript or TypeScript files. It provides:
|
8
|
+
|
9
|
+
- A runner, which executes the provided transform for each file passed to it. It also outputs a summary of how many files have **not** been transformed.
|
10
|
+
- A wrapper around [recast](https://github.com/benjamn/recast), providing a different API. Recast is an AST-to-AST transform tool and also tries to preserve the style of original code
|
11
|
+
as much as possible.
|
12
|
+
|
13
|
+
## How does jscodeshift work?
|
14
|
+
|
15
|
+
<Steps>
|
16
|
+
1. **Parsing Code into AST**
|
17
|
+
|
18
|
+
First, jscodeshift takes your JavaScript code and converts it into an Abstract Syntax Tree (AST). An AST is a tree representation of your code where each node represents a different part of the code, like variables, functions, and expressions.
|
19
|
+
|
20
|
+
2. **Transforming the AST**
|
21
|
+
|
22
|
+
Using jscodeshift, you can navigate through the AST and apply transformations. For example, you can find all instances of a certain function and rename it or change its parameters.
|
23
|
+
|
24
|
+
3. **Generating Code from AST**
|
25
|
+
|
26
|
+
After transforming the AST, jscodeshift converts it back into JavaScript code. The result is your original code with the specified changes applied.
|
27
|
+
</Steps>
|
28
|
+
|
29
|
+
## Installation
|
30
|
+
|
31
|
+
Get jscodeshift from [npm](https://www.npmjs.com/package/jscodeshift):
|
32
|
+
|
33
|
+
```
|
34
|
+
$ npm install -g jscodeshift
|
35
|
+
```
|
36
|
+
|
37
|
+
This will install the runner as `jscodeshift`.
|
38
|
+
|
39
|
+
|
40
|
+
## Getting started
|
41
|
+
|
42
|
+
<CardGrid>
|
43
|
+
<LinkCard title="Build jscodeshift codemods" href="/build/api-reference/" />
|
44
|
+
<LinkCard title="Run jscodeshift codemods" href="/run/cli/" />
|
45
|
+
</CardGrid>
|
@@ -0,0 +1,161 @@
|
|
1
|
+
---
|
2
|
+
title: CLI Reference
|
3
|
+
---
|
4
|
+
|
5
|
+
import { Aside } from '@astrojs/starlight/components';
|
6
|
+
|
7
|
+
The `jscodeshift` command-line interface (CLI) allows you to run jscodeshift codemods using a terminal or through an automated system.
|
8
|
+
|
9
|
+
## Usage
|
10
|
+
|
11
|
+
You can use the `jscodeshift` command to run codemods in 4 different ways
|
12
|
+
|
13
|
+
**Option 1: Run from `transform.js` file in current working directory:**
|
14
|
+
|
15
|
+
```bash
|
16
|
+
jscodeshift [OPTION]... PATH...
|
17
|
+
```
|
18
|
+
|
19
|
+
This automatically looks for a `transform.js` file in the current working directory and attempts to run the transform over the specified `PATH`.
|
20
|
+
|
21
|
+
**Option 2: Run from specific transform file:**
|
22
|
+
|
23
|
+
```bash
|
24
|
+
jscodeshift [OPTION]... -t TRANSFORM_PATH PATH...
|
25
|
+
```
|
26
|
+
|
27
|
+
This allows you to specify a path to a transform file and run the transform over the specified `PATH`.
|
28
|
+
|
29
|
+
**Option 3: Run from specific transform URL:**
|
30
|
+
|
31
|
+
```bash
|
32
|
+
jscodeshift [OPTION]... -t URL PATH...
|
33
|
+
```
|
34
|
+
|
35
|
+
This allows you to specify a URL to a transform file and run the transform over the specified `PATH`.
|
36
|
+
|
37
|
+
**Option 4: Apply transform to standard input:**
|
38
|
+
|
39
|
+
```bash
|
40
|
+
jscodeshift [OPTION]... --stdin < file_list.txt
|
41
|
+
```
|
42
|
+
|
43
|
+
Using `--stdin` allows you to run the transform over every line of standard input provided in `file_list.txt`.
|
44
|
+
|
45
|
+
|
46
|
+
## Options
|
47
|
+
|
48
|
+
### `--(no-)babel`
|
49
|
+
|
50
|
+
`default: true`
|
51
|
+
|
52
|
+
This allows you to apply babeljs to the transform file.
|
53
|
+
|
54
|
+
### `--cpus=N`
|
55
|
+
|
56
|
+
`aliases: -c`
|
57
|
+
|
58
|
+
`default: max(all - 1, 1)`
|
59
|
+
|
60
|
+
This allows you to start at most N child processes to process source files.
|
61
|
+
|
62
|
+
### `--(no-)dry`
|
63
|
+
|
64
|
+
`aliases: -d`
|
65
|
+
|
66
|
+
`default: false`
|
67
|
+
|
68
|
+
This allows you to dry run the codemod. Dry running is useful when you need to see how a codemod will affect your project without making changes to your files.
|
69
|
+
|
70
|
+
### `--extensions=[EXT]`
|
71
|
+
|
72
|
+
`default: js`
|
73
|
+
|
74
|
+
Allows you to specify the extension of the files to be transformed.
|
75
|
+
|
76
|
+
|
77
|
+
### `--help`
|
78
|
+
|
79
|
+
`aliases: -h`
|
80
|
+
|
81
|
+
Allows you to print the help menu.
|
82
|
+
|
83
|
+
### `--ignore-config=[FILE] ...`
|
84
|
+
|
85
|
+
Allows you to ignore files if they match patterns sourced from a configuration file (e.g. a .gitignore).
|
86
|
+
|
87
|
+
### `--ignore-pattern=[GLOB] ...`
|
88
|
+
|
89
|
+
Allows you to ignore files that match a provided glob expression.
|
90
|
+
|
91
|
+
### `--(no-)gitignore`
|
92
|
+
|
93
|
+
`default: false`
|
94
|
+
|
95
|
+
Allows you to add entries to the current directory's .gitignore file.
|
96
|
+
|
97
|
+
### `--parser=[PARSER]`
|
98
|
+
|
99
|
+
`default: babel`
|
100
|
+
|
101
|
+
`available options: babel|babylon|flow|ts|tsx`
|
102
|
+
|
103
|
+
Allows you to specify the parser to use for parsing the source files.
|
104
|
+
|
105
|
+
### `--parser-config=[FILE]`
|
106
|
+
|
107
|
+
Allows you to specify path to a JSON file containing a custom parser configuration for flow or babylon.
|
108
|
+
|
109
|
+
### `--(no-)print`
|
110
|
+
|
111
|
+
`aliases: -p`
|
112
|
+
|
113
|
+
`default: false`
|
114
|
+
|
115
|
+
Allows you to print transformed files to stdout, useful for development.
|
116
|
+
|
117
|
+
### `--(no-)run-in-band`
|
118
|
+
|
119
|
+
`default: false`
|
120
|
+
|
121
|
+
Allows `jscodeshift` to run serially in the current process.
|
122
|
+
|
123
|
+
### `--(no-)silent`
|
124
|
+
|
125
|
+
`aliases: -s`
|
126
|
+
|
127
|
+
`default: false`
|
128
|
+
|
129
|
+
Allows you to run silently (prevent writing to stdout or stderr).
|
130
|
+
|
131
|
+
### `--(no-)stdin`
|
132
|
+
|
133
|
+
`default: false`
|
134
|
+
|
135
|
+
Allows you to run the transform over every line of standard input.
|
136
|
+
|
137
|
+
### `--transform=[FILE]`
|
138
|
+
|
139
|
+
`aliases: -t`
|
140
|
+
|
141
|
+
`default: ./transform.js`
|
142
|
+
|
143
|
+
Allows you to specify a path to the transform file. Can be either a local path or url.
|
144
|
+
|
145
|
+
### `--verbose=[MODE]`
|
146
|
+
|
147
|
+
`aliases: -v`
|
148
|
+
|
149
|
+
`available options: 0|1|2`
|
150
|
+
|
151
|
+
`default: 0`
|
152
|
+
|
153
|
+
Allows you to show more information about the transform process.
|
154
|
+
|
155
|
+
### `--version`
|
156
|
+
|
157
|
+
Allows you to print your `jscodeshift` version.
|
158
|
+
|
159
|
+
### `--fail-on-error`
|
160
|
+
|
161
|
+
Allows you to return a 1 exit code when errors were found during execution of codemods.
|
@@ -5,27 +5,27 @@
|
|
5
5
|
|
6
6
|
**npm-check-updates upgrades your package.json dependencies to the _latest_ versions, ignoring specified versions.**
|
7
7
|
|
8
|
-
- maintains existing semantic versioning _policies_, i.e. `"react": "^
|
8
|
+
- maintains existing semantic versioning _policies_, i.e. `"react": "^17.0.2"` to `"react": "^18.3.1"`.
|
9
9
|
- _only_ modifies package.json file. Run `npm install` to update your installed packages and package-lock.json.
|
10
10
|
- sensible defaults, but highly customizable
|
11
|
+
- compatible with npm, yarn, pnpm, deno, and bun
|
11
12
|
- CLI and module usage
|
12
|
-
- compatible with: `npm`, `yarn`, `pnpm`, `deno`, `bun`
|
13
13
|
|
14
|
-
|
14
|
+
<img width="500" alt="example output" src="https://github.com/user-attachments/assets/4808618b-ac20-4fc0-92e0-a777de70a2b6">
|
15
15
|
|
16
|
-
|
17
|
-
|
18
|
-
|
16
|
+
$${\color{red}Red}$$ major upgrade (and all [major version zero](https://semver.org/#spec-item-4))<br/>
|
17
|
+
$${\color{cyan}Cyan}$$ minor upgrade<br/>
|
18
|
+
$${\color{green}Green}$$ patch upgrade<br/>
|
19
19
|
|
20
20
|
## Installation
|
21
21
|
|
22
|
-
Install globally
|
22
|
+
Install globally to use `npm-check-updates` or the shorter `ncu`:
|
23
23
|
|
24
24
|
```sh
|
25
25
|
npm install -g npm-check-updates
|
26
26
|
```
|
27
27
|
|
28
|
-
Or run with [npx](https://docs.npmjs.com/cli/v7/commands/npx):
|
28
|
+
Or run with [npx](https://docs.npmjs.com/cli/v7/commands/npx) (only the long form is supported):
|
29
29
|
|
30
30
|
```sh
|
31
31
|
npx npm-check-updates
|
@@ -89,7 +89,7 @@ Combine with `--format group` for a truly _luxe_ experience:
|
|
89
89
|
|
90
90
|
## Filter packages
|
91
91
|
|
92
|
-
Filter packages using the `--filter` option or adding additional cli arguments
|
92
|
+
Filter packages using the `--filter` option or adding additional cli arguments:
|
93
93
|
|
94
94
|
```sh
|
95
95
|
# upgrade only mocha
|
@@ -97,26 +97,36 @@ ncu mocha
|
|
97
97
|
ncu -f mocha
|
98
98
|
ncu --filter mocha
|
99
99
|
|
100
|
+
# upgrade only chalk, mocha, and react
|
101
|
+
ncu chalk mocha react
|
102
|
+
ncu chalk, mocha, react
|
103
|
+
ncu -f "chalk mocha react"
|
104
|
+
```
|
105
|
+
|
106
|
+
Filter with wildcards or regex:
|
107
|
+
|
108
|
+
```sh
|
100
109
|
# upgrade packages that start with "react-"
|
101
110
|
ncu react-*
|
102
111
|
ncu "/^react-.*$/"
|
112
|
+
```
|
103
113
|
|
114
|
+
Exclude specific packages with the `--reject` option or prefixing a filter with `!`. Supports strings, wildcards, globs, comma-or-space-delimited lists, and regex:
|
115
|
+
|
116
|
+
```sh
|
104
117
|
# upgrade everything except nodemon
|
105
118
|
ncu \!nodemon
|
106
119
|
ncu -x nodemon
|
107
120
|
ncu --reject nodemon
|
108
121
|
|
109
|
-
# upgrade only chalk, mocha, and react
|
110
|
-
ncu chalk mocha react
|
111
|
-
ncu chalk, mocha, react
|
112
|
-
ncu -f "chalk mocha react"
|
113
|
-
|
114
122
|
# upgrade packages that do not start with "react-".
|
115
123
|
ncu \!react-*
|
116
124
|
ncu '/^(?!react-).*$/' # mac/linux
|
117
125
|
ncu "/^(?!react-).*$/" # windows
|
118
126
|
```
|
119
127
|
|
128
|
+
Advanced filters: [filter](https://github.com/raineorshine/npm-check-updates#filter), [filterResults](https://github.com/raineorshine/npm-check-updates#filterresults), [filterVersion](https://github.com/raineorshine/npm-check-updates#filterversion)
|
129
|
+
|
120
130
|
## How dependency updates are determined
|
121
131
|
|
122
132
|
- Direct dependencies are updated to the latest stable version:
|
@@ -134,18 +144,21 @@ ncu "/^(?!react-).*$/" # windows
|
|
134
144
|
- `*` → `*`
|
135
145
|
- Prerelease versions are ignored by default.
|
136
146
|
- Use `--pre` to include prerelease versions (e.g. `alpha`, `beta`, `build1235`)
|
137
|
-
-
|
138
|
-
-
|
139
|
-
-
|
140
|
-
-
|
141
|
-
-
|
142
|
-
-
|
147
|
+
- Choose what level to upgrade to:
|
148
|
+
- With `--target semver`, update according to your specified [semver](https://semver.org/) version ranges:
|
149
|
+
- `^1.1.0` → `^1.9.99`
|
150
|
+
- With `--target minor`, strictly update the patch and minor versions (including major version zero):
|
151
|
+
- `0.1.0` → `0.2.1`
|
152
|
+
- With `--target patch`, strictly update the patch version (including major version zero):
|
153
|
+
- `0.1.0` → `0.1.2`
|
154
|
+
- With `--target @next`, update to the version published on the `next` tag:
|
155
|
+
- `0.1.0` -> `0.1.1-next.1`
|
143
156
|
|
144
157
|
## Options
|
145
158
|
|
146
159
|
Options are merged with the following precedence:
|
147
160
|
|
148
|
-
1.
|
161
|
+
1. Command line options
|
149
162
|
2. Local [Config File](#config-file)
|
150
163
|
3. Project Config File
|
151
164
|
4. User Config File
|