forked from MapComplete/MapComplete
		
	Add warning for autogenerated files, add newline to generated files
This commit is contained in:
		
							parent
							
								
									b5c1f1f11e
								
							
						
					
					
						commit
						48c6a3b0d7
					
				
					 1 changed files with 8 additions and 1 deletions
				
			
		|  | @ -64,7 +64,14 @@ function WriteFile( | |||
| 
 | ||||
|     md.replace(/\n\n\n+/g, "\n\n") | ||||
| 
 | ||||
|     writeFileSync(filename, md) | ||||
|     if (!md.endsWith("\n")) { | ||||
|         md += "\n" | ||||
|     } | ||||
| 
 | ||||
|     const warnAutomated = | ||||
|         "[//]: # (WARNING: this file is automatically generated. Please find the sources at the bottom and edit those sources)" | ||||
| 
 | ||||
|     writeFileSync(filename, warnAutomated + md) | ||||
| } | ||||
| 
 | ||||
| /** | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue