node_mutation 1.24.2 → 1.24.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/Gemfile.lock +5 -5
- data/README.md +6 -3
- data/lib/node_mutation/version.rb +1 -1
- data/node_mutation.gemspec +3 -3
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a1838915f4699a2c9bc566d05d38ed23f892b31a0a44d3812f4fe54b760a213f
|
4
|
+
data.tar.gz: 0fc0b9aac1857fc18675578da657a663786eb5ffcb43b2b2f4c27a013487eb78
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 699e09b43684f17ad6d0ab0b3902cc2910eb5ba53a870a5a2dfb6bb1c19b5df770a747c8d8c4e22fb8414cfac7f25acb1e3498465f0f8279abc458544eb4d8b5
|
7
|
+
data.tar.gz: 3702e772e0379b37d1adea9b7024ebeafe2ea0e77a8b5263a1d9a32b62d581be58e64d1a735d6ac0b7b6bbc3440cfbd477744d03e68da58f5b426fd5209c470b
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
node_mutation (1.24.
|
4
|
+
node_mutation (1.24.3)
|
5
5
|
|
6
6
|
GEM
|
7
7
|
remote: https://rubygems.org/
|
@@ -37,11 +37,11 @@ GEM
|
|
37
37
|
parser (3.3.0.5)
|
38
38
|
ast (~> 2.4.1)
|
39
39
|
racc
|
40
|
-
parser_node_ext (1.
|
40
|
+
parser_node_ext (1.3.0)
|
41
41
|
parser
|
42
42
|
prettier_print (1.2.1)
|
43
|
-
prism (0.
|
44
|
-
prism_ext (0.
|
43
|
+
prism (0.25.0)
|
44
|
+
prism_ext (0.3.0)
|
45
45
|
prism
|
46
46
|
pry (0.14.1)
|
47
47
|
coderay (~> 1.1)
|
@@ -67,7 +67,7 @@ GEM
|
|
67
67
|
shellany (0.0.1)
|
68
68
|
syntax_tree (6.2.0)
|
69
69
|
prettier_print (>= 1.2.0)
|
70
|
-
syntax_tree_ext (0.
|
70
|
+
syntax_tree_ext (0.8.1)
|
71
71
|
syntax_tree
|
72
72
|
thor (1.2.1)
|
73
73
|
|
data/README.md
CHANGED
@@ -1,5 +1,8 @@
|
|
1
1
|
# NodeMutation
|
2
2
|
|
3
|
+
[![Build Status](https://github.com/synvert-hq/node-mutation-ruby/actions/workflows/main.yml/badge.svg)](https://github.com/synvert-hq/node-mutation-ruby/actions/workflows/main.yml)
|
4
|
+
[![Gem Version](https://img.shields.io/gem/v/node_mutation.svg)](https://rubygems.org/gems/node_mutation)
|
5
|
+
|
3
6
|
NodeMutation provides a set of APIs to rewrite node source code.
|
4
7
|
|
5
8
|
## Installation
|
@@ -81,14 +84,14 @@ mutation.replace node, '{{arguments.-1.on_value}}', with: ':update'
|
|
81
84
|
source # after_commit :do_index, on: :update, if: :indexable?
|
82
85
|
```
|
83
86
|
|
84
|
-
See more in [ParserAdapter](https://
|
87
|
+
See more in [ParserAdapter](https://synvert-hq.github.io/node-mutation-ruby/NodeMutation/ParserAdapter.html) and [SyntaxTreeAdapter](https://synvert-hq.github.io/node-mutation-ruby/NodeMutation/SyntaxTreeAdapter.html)
|
85
88
|
|
86
89
|
## Configuration
|
87
90
|
|
88
91
|
### adapter
|
89
92
|
|
90
93
|
Different parsers, like parse and ripper, will generate different AST nodes, to make NodeMutation work for them all,
|
91
|
-
we define an [Adapter](https://github.com/
|
94
|
+
we define an [Adapter](https://github.com/synvert-hq/node-mutation-ruby/blob/main/lib/node_mutation/adapter.rb) interface,
|
92
95
|
if you implement the Adapter interface, you can set it as NodeMutation's adapter.
|
93
96
|
|
94
97
|
### strategy
|
@@ -116,4 +119,4 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
116
119
|
|
117
120
|
## Contributing
|
118
121
|
|
119
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
122
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/synvert-hq/node_mutation.
|
data/node_mutation.gemspec
CHANGED
@@ -10,12 +10,12 @@ Gem::Specification.new do |spec|
|
|
10
10
|
|
11
11
|
spec.summary = "ast node mutation apis"
|
12
12
|
spec.description = "ast node mutation apis"
|
13
|
-
spec.homepage = "https://github.com/
|
13
|
+
spec.homepage = "https://github.com/synvert-hq/node-mutation-ruby"
|
14
14
|
spec.required_ruby_version = ">= 2.6.0"
|
15
15
|
|
16
16
|
spec.metadata["homepage_uri"] = spec.homepage
|
17
|
-
spec.metadata["source_code_uri"] = "https://github.com/
|
18
|
-
spec.metadata["changelog_uri"] = "https://github.com/
|
17
|
+
spec.metadata["source_code_uri"] = "https://github.com/synvert-hq/node-mutation-ruby"
|
18
|
+
spec.metadata["changelog_uri"] = "https://github.com/synvert-hq/node-mutation-ruby/blob/master/CHANGELOG.md"
|
19
19
|
|
20
20
|
# Specify which files should be added to the gem when it is released.
|
21
21
|
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: node_mutation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.24.
|
4
|
+
version: 1.24.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Richard Huang
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-04-07 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: ast node mutation apis
|
14
14
|
email:
|
@@ -53,12 +53,12 @@ files:
|
|
53
53
|
- sig/node_mutation/result.rbs
|
54
54
|
- sig/node_mutation/strategy.rbs
|
55
55
|
- sig/node_mutation/struct.rbs
|
56
|
-
homepage: https://github.com/
|
56
|
+
homepage: https://github.com/synvert-hq/node-mutation-ruby
|
57
57
|
licenses: []
|
58
58
|
metadata:
|
59
|
-
homepage_uri: https://github.com/
|
60
|
-
source_code_uri: https://github.com/
|
61
|
-
changelog_uri: https://github.com/
|
59
|
+
homepage_uri: https://github.com/synvert-hq/node-mutation-ruby
|
60
|
+
source_code_uri: https://github.com/synvert-hq/node-mutation-ruby
|
61
|
+
changelog_uri: https://github.com/synvert-hq/node-mutation-ruby/blob/master/CHANGELOG.md
|
62
62
|
post_install_message:
|
63
63
|
rdoc_options: []
|
64
64
|
require_paths:
|