redput 4.2.1 → 4.3.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,13 @@
1
+ 2026.05.05, v4.3.0
2
+
3
+ feature:
4
+ - 4994885 redput: parse-plugin: trailing spaces
5
+
6
+ 2026.04.21, v4.2.2
7
+
8
+ feature:
9
+ - 8c2ff9c redput: montag v2.0.1
10
+
1
11
  2026.03.04, v4.2.1
2
12
 
3
13
  feature:
@@ -8,9 +8,12 @@ export const replace = () => ({
8
8
  '[__a, __b]': ({__a, __b}, path) => {
9
9
  const [__aPath, __bPath] = path.get('elements');
10
10
  const status = isStringLiteral(__a) ? __a.value : __aPath.toString();
11
- const name = isStringLiteral(__b) ? __b.value : __bPath
12
- .toString()
13
- .replace(/\s/g, '') + '';
11
+
12
+ const name = isStringLiteral(__b) ? __b.value
13
+ : __bPath
14
+ .toString()
15
+ .replace(/\s/g, '') +
16
+ '';
14
17
 
15
18
  return `["${status}", "${name}"]`;
16
19
  },
@@ -20,7 +20,7 @@ export const parsePlugin = (raw) => {
20
20
  function parseComment(comment) {
21
21
  const raw = comment
22
22
  .replace('//', '')
23
- .trimStart();
23
+ .trim();
24
24
 
25
25
  if (/^[a-z-]+$/.test(raw))
26
26
  return ['', raw];
@@ -44,6 +44,7 @@ const createAddRule = (options) => ({__object}, path) => {
44
44
  }));
45
45
 
46
46
  __object.properties.push(node);
47
+
47
48
  return path;
48
49
  }
49
50
 
@@ -50,6 +50,7 @@ export const writeNestedTests = async (name, report) => {
50
50
  export const updateNestedIndex = async (name, options) => {
51
51
  const source = await readFile('./index.js', 'utf8');
52
52
  const code = addRule(name, source, options);
53
+
53
54
  await writeFile(`./index.js`, code);
54
55
  };
55
56
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "redput",
3
- "version": "4.2.1",
3
+ "version": "4.3.0",
4
4
  "description": "CLI tool to convert source from 🐊Putout Editor to files",
5
5
  "main": "lib/redput.js",
6
6
  "bin": {
@@ -73,7 +73,7 @@
73
73
  "eslint": "^10.0.0",
74
74
  "eslint-plugin-putout": "^31.0.0",
75
75
  "madrun": "^13.0.0",
76
- "montag": "^1.2.1",
76
+ "montag": "^2.0.1",
77
77
  "nodemon": "^3.0.1",
78
78
  "redlint": "^6.0.0",
79
79
  "superc8": "^12.2.4",