mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-10-27 01:51:34 +08:00 
			
		
		
		
	refactor(forge.config): call getExtraResourcesForPlatform once only
This commit is contained in:
		
							parent
							
								
									e0862ce8f3
								
							
						
					
					
						commit
						2b83470de6
					
				| @ -3,6 +3,7 @@ const fs = require("fs-extra"); | ||||
| 
 | ||||
| const APP_NAME = "TriliumNext Notes"; | ||||
| 
 | ||||
| const extraResourcesForPlatform = getExtraResourcesForPlatform(); | ||||
| const baseLinuxMakerConfigOptions = { | ||||
|   icon: "./images/app-icons/png/128x128.png", | ||||
|   desktopTemplate: path.resolve("./bin/electron-forge/desktop.ejs"), | ||||
| @ -17,7 +18,7 @@ module.exports = { | ||||
|         icon: "./images/app-icons/icon", | ||||
|         extraResource: [ | ||||
|             // Moved to root
 | ||||
|             ...getExtraResourcesForPlatform(), | ||||
|             ...extraResourcesForPlatform, | ||||
| 
 | ||||
|             // Moved to resources (TriliumNext Notes.app/Contents/Resources on macOS)
 | ||||
|             "translations/", | ||||
| @ -25,8 +26,7 @@ module.exports = { | ||||
|         ], | ||||
|         afterComplete: [ | ||||
|             (buildPath, _electronVersion, platform, _arch, callback) => { | ||||
|                 const extraResources = getExtraResourcesForPlatform(); | ||||
|                 for (const resource of extraResources) { | ||||
|                 for (const resource of extraResourcesForPlatform) { | ||||
|                     const baseName = path.basename(resource); | ||||
| 
 | ||||
|                     // prettier-ignore
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Panagiotis Papadopoulos
						Panagiotis Papadopoulos