redput 2.7.1 → 2.9.0

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/ChangeLog CHANGED
@@ -1,3 +1,19 @@
1
+ 2025.03.15, v2.9.0
2
+
3
+ feature:
4
+ - 582bd8c redput: @putout/test v12.1.0
5
+ - c01a6ce redput: @putout/plugin-declare-before-reference v6.2.0
6
+ - 6f873ff redput: eslint-plugin-putout v25.2.0
7
+ - 95c939b redput: @putout/plugin-declare v5.0.0
8
+
9
+ 2025.02.13, v2.8.0
10
+
11
+ feature:
12
+ - f10ab2f redput: link instead of name
13
+ - 6c5af63 redput: @putout/plugin-remove-unused-variables v12.0.0
14
+ - 2b2a84b redput: @putout/plugin-putout v23.4.1
15
+ - a0f4608 redput: @putout/plugin-nodejs v14.0.1
16
+
1
17
  2025.01.29, v2.7.1
2
18
 
3
19
  feature:
package/lib/redput.js CHANGED
@@ -27,6 +27,11 @@ export const redput = async (link, {token}) => {
27
27
  lines,
28
28
  } = parsePlugin(raw);
29
29
 
30
+ if (name.startsWith('http'))
31
+ return [
32
+ Error(`Wrong name: '${name}'`),
33
+ ];
34
+
30
35
  const rule = lines.join('\n');
31
36
  const report = getReport(rule);
32
37
 
@@ -4,7 +4,7 @@ import {
4
4
  template,
5
5
  } from 'putout';
6
6
 
7
- const {StringLiteral, SpreadElement} = types;
7
+ const {spreadElement, stringLiteral} = types;
8
8
  const {traverse} = operator;
9
9
 
10
10
  export const report = () => `Insert 'getRule()'`;
@@ -35,16 +35,16 @@ export const replace = ({options}) => ({
35
35
  const {name, ruleOptions} = options;
36
36
 
37
37
  if (ruleOptions) {
38
- const node = SpreadElement(createRuleWithOptions({
39
- name: StringLiteral(name),
38
+ const node = spreadElement(createRuleWithOptions({
39
+ name: stringLiteral(name),
40
40
  }));
41
41
 
42
42
  __object.properties.push(node);
43
43
  return path;
44
44
  }
45
45
 
46
- const node = SpreadElement(createRule({
47
- name: StringLiteral(name),
46
+ const node = spreadElement(createRule({
47
+ name: stringLiteral(name),
48
48
  }));
49
49
 
50
50
  __object.properties.push(node);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "redput",
3
- "version": "2.7.1",
3
+ "version": "2.9.0",
4
4
  "description": "CLI tool to convert source from 🐊Putout Editor to files",
5
5
  "main": "lib/redput.js",
6
6
  "bin": {
@@ -56,11 +56,11 @@
56
56
  },
57
57
  "dependencies": {
58
58
  "@putout/plugin-convert-esm-to-commonjs": "^6.0.0",
59
- "@putout/plugin-declare": "^4.0.0",
60
- "@putout/plugin-declare-before-reference": "^5.1.0",
61
- "@putout/plugin-nodejs": "^13.1.1",
62
- "@putout/plugin-putout": "^22.0.0",
63
- "@putout/plugin-remove-unused-variables": "^11.0.0",
59
+ "@putout/plugin-declare": "^5.0.0",
60
+ "@putout/plugin-declare-before-reference": "^6.2.0",
61
+ "@putout/plugin-nodejs": "^14.0.1",
62
+ "@putout/plugin-putout": "^23.4.1",
63
+ "@putout/plugin-remove-unused-variables": "^12.0.0",
64
64
  "node-fetch": "^3.3.2",
65
65
  "octokit": "^4.0.2",
66
66
  "putout": "^38.0.0",
@@ -69,11 +69,11 @@
69
69
  "try-to-catch": "^3.0.1"
70
70
  },
71
71
  "devDependencies": {
72
- "@putout/test": "^11.0.0",
72
+ "@putout/test": "^12.1.0",
73
73
  "c8": "^10.1.2",
74
74
  "escover": "^4.0.1",
75
75
  "eslint": "^9.0.0",
76
- "eslint-plugin-putout": "^24.0.0",
76
+ "eslint-plugin-putout": "^25.2.0",
77
77
  "madrun": "^10.0.0",
78
78
  "montag": "^1.2.1",
79
79
  "nodemon": "^3.0.1",