| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  | { | 
					
						
							|  |  |  |   lib, | 
					
						
							|  |  |  |   fetchFromGitHub, | 
					
						
							|  |  |  |   rustPlatform, | 
					
						
							|  |  |  |   versionCheckHook, | 
					
						
							|  |  |  |   nix-update-script, | 
					
						
							|  |  |  | }: | 
					
						
							| 
									
										
										
										
											2025-03-07 22:13:24 -03:00
										 |  |  | rustPlatform.buildRustPackage (finalAttrs: { | 
					
						
							| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  |   pname = "iwe"; | 
					
						
							| 
									
										
										
										
											2025-06-12 06:00:24 +00:00
										 |  |  |   version = "0.0.33"; | 
					
						
							| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  | 
 | 
					
						
							|  |  |  |   src = fetchFromGitHub { | 
					
						
							|  |  |  |     owner = "iwe-org"; | 
					
						
							|  |  |  |     repo = "iwe"; | 
					
						
							| 
									
										
										
										
											2025-03-07 22:13:24 -03:00
										 |  |  |     tag = "iwe-v${finalAttrs.version}"; | 
					
						
							| 
									
										
										
										
											2025-06-12 06:00:24 +00:00
										 |  |  |     hash = "sha256-PjonpAyq6FPJs5mo4W3z9yIVU8auGGtTrK/GBxMcPbk="; | 
					
						
							| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  |   }; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   useFetchCargoVendor = true; | 
					
						
							| 
									
										
										
										
											2025-06-12 06:00:24 +00:00
										 |  |  |   cargoHash = "sha256-EfoDpa2hN9W2unci4rIi4gjlJV2NzdU77FbOW0OTu2c="; | 
					
						
							| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  | 
 | 
					
						
							|  |  |  |   cargoBuildFlags = [ | 
					
						
							|  |  |  |     "--package=iwe" | 
					
						
							|  |  |  |     "--package=iwes" | 
					
						
							|  |  |  |   ]; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   nativeInstallCheckInputs = [ versionCheckHook ]; | 
					
						
							|  |  |  |   versionCheckProgramArg = "--version"; | 
					
						
							|  |  |  |   doInstallCheck = true; | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-03-07 22:16:11 -03:00
										 |  |  |   passthru.updateScript = nix-update-script { | 
					
						
							|  |  |  |     extraArgs = [ | 
					
						
							|  |  |  |       "--version-regex" | 
					
						
							|  |  |  |       "^iwe-v(.*)$" | 
					
						
							|  |  |  |     ]; | 
					
						
							|  |  |  |   }; | 
					
						
							| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  | 
 | 
					
						
							|  |  |  |   meta = { | 
					
						
							|  |  |  |     description = "Personal knowledge management system (editor plugin & command line utility)"; | 
					
						
							|  |  |  |     homepage = "https://iwe.md/"; | 
					
						
							|  |  |  |     license = lib.licenses.asl20; | 
					
						
							| 
									
										
										
										
											2025-03-07 22:18:25 -03:00
										 |  |  |     maintainers = with lib.maintainers; [ | 
					
						
							|  |  |  |       phrmendes | 
					
						
							|  |  |  |       HeitorAugustoLN | 
					
						
							|  |  |  |     ]; | 
					
						
							| 
									
										
										
										
											2025-02-05 13:32:58 -03:00
										 |  |  |     mainProgram = "iwe"; | 
					
						
							|  |  |  |   }; | 
					
						
							| 
									
										
										
										
											2025-03-07 22:13:24 -03:00
										 |  |  | }) |