mirror of
				https://gitea.invidious.io/iv-org/shard-ameba.git
				synced 2024-08-15 00:53:29 +00:00 
			
		
		
		
	Rename read_rule_doc -> read_type_doc
				
					
				
			Also, move the helper script into the `contrib` directory
This commit is contained in:
		
							parent
							
								
									3d61254739
								
							
						
					
					
						commit
						d55b93c866
					
				
					 2 changed files with 3 additions and 3 deletions
				
			
		| 
						 | 
					@ -138,8 +138,8 @@ module Ameba::Rule
 | 
				
			||||||
      end
 | 
					      end
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    private macro read_rule_doc(filepath = __FILE__)
 | 
					    private macro read_type_doc(filepath = __FILE__)
 | 
				
			||||||
      {{ run("../../read_rule_doc",
 | 
					      {{ run("../../contrib/read_type_doc",
 | 
				
			||||||
           @type.name.split("::").last,
 | 
					           @type.name.split("::").last,
 | 
				
			||||||
           filepath
 | 
					           filepath
 | 
				
			||||||
         ).chomp.stringify }}.presence
 | 
					         ).chomp.stringify }}.presence
 | 
				
			||||||
| 
						 | 
					@ -160,7 +160,7 @@ module Ameba::Rule
 | 
				
			||||||
      #
 | 
					      #
 | 
				
			||||||
      # MyRule.parsed_doc # => "This is a test rule.\nDoes nothing."
 | 
					      # MyRule.parsed_doc # => "This is a test rule.\nDoes nothing."
 | 
				
			||||||
      # ```
 | 
					      # ```
 | 
				
			||||||
      class_getter parsed_doc : String? = read_rule_doc
 | 
					      class_getter parsed_doc : String? = read_type_doc
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
  end
 | 
					  end
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue