feat: created mapillary desktop uploader dirivation
This commit is contained in:
		
							parent
							
								
									0f8faadd80
								
							
						
					
					
						commit
						ffcba0d714
					
				
					 2 changed files with 45 additions and 0 deletions
				
			
		
							
								
								
									
										42
									
								
								modules/common-modules/pkgs/mapillary-uploader.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										42
									
								
								modules/common-modules/pkgs/mapillary-uploader.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,42 @@ | |||
| { | ||||
|   lib, | ||||
|   fetchurl, | ||||
|   appimageTools, | ||||
| }: let | ||||
|   pname = "mapillary-uploader"; | ||||
|   version = "4.7.2"; # Based on the application output | ||||
| 
 | ||||
|   src = fetchurl { | ||||
|     url = "https://tools.mapillary.com/uploader/download/linux"; | ||||
|     name = "mapillary-uploader.AppImage"; | ||||
|     sha256 = "sha256-Oyx7AIdA/2mwBaq7UzXOoyq/z2SU2sViMN40sY2RCQw="; | ||||
|   }; | ||||
| 
 | ||||
|   appimageContents = appimageTools.extractType2 { | ||||
|     inherit pname version src; | ||||
|   }; | ||||
| in | ||||
|   appimageTools.wrapType2 { | ||||
|     inherit pname version src; | ||||
| 
 | ||||
|     extraInstallCommands = '' | ||||
|       # Install desktop file | ||||
|       install -Dm644 ${appimageContents}/mapillary-desktop-uploader.desktop $out/share/applications/mapillary-uploader.desktop | ||||
| 
 | ||||
|       # Install icon | ||||
|       install -Dm644 ${appimageContents}/usr/share/icons/hicolor/0x0/apps/mapillary-desktop-uploader.png $out/share/pixmaps/mapillary-uploader.png | ||||
| 
 | ||||
|       # Fix desktop file paths | ||||
|       substituteInPlace $out/share/applications/mapillary-uploader.desktop \ | ||||
|         --replace 'Exec=AppRun' 'Exec=${pname}' | ||||
|     ''; | ||||
| 
 | ||||
|     meta = with lib; { | ||||
|       description = "Mapillary Desktop Uploader - Upload street-level imagery to Mapillary"; | ||||
|       homepage = "https://www.mapillary.com/"; | ||||
|       license = licenses.unfree; # Mapillary's license terms | ||||
|       maintainers = []; | ||||
|       platforms = ["x86_64-linux"]; | ||||
|       sourceProvenance = with sourceTypes; [binaryNativeCode]; | ||||
|     }; | ||||
|   } | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue