forked from jan-leila/nix-config
		
	fixed shares between devices
This commit is contained in:
		
							parent
							
								
									a7888cb164
								
							
						
					
					
						commit
						a7c734871b
					
				
					 4 changed files with 33 additions and 35 deletions
				
			
		|  | @ -121,10 +121,12 @@ | ||||||
|     sync = { |     sync = { | ||||||
|       enable = true; |       enable = true; | ||||||
|       folders = { |       folders = { | ||||||
|         share.enable = true; |         share = { | ||||||
|  |           enable = true; | ||||||
|  |           calendar.enable = true; | ||||||
|  |         }; | ||||||
|         leyla = { |         leyla = { | ||||||
|           documents.enable = true; |           documents.enable = true; | ||||||
|           calendar.enable = true; |  | ||||||
|           notes.enable = true; |           notes.enable = true; | ||||||
|         }; |         }; | ||||||
|       }; |       }; | ||||||
|  |  | ||||||
|  | @ -22,8 +22,6 @@ | ||||||
|       folders = { |       folders = { | ||||||
|         leyla = { |         leyla = { | ||||||
|           documents.enable = true; |           documents.enable = true; | ||||||
|           calendar.enable = true; |  | ||||||
|           notes.enable = true; |  | ||||||
|         }; |         }; | ||||||
|       }; |       }; | ||||||
|     }; |     }; | ||||||
|  |  | ||||||
|  | @ -34,8 +34,6 @@ | ||||||
|       folders = { |       folders = { | ||||||
|         leyla = { |         leyla = { | ||||||
|           documents.enable = true; |           documents.enable = true; | ||||||
|           calendar.enable = true; |  | ||||||
|           notes.enable = true; |  | ||||||
|         }; |         }; | ||||||
|       }; |       }; | ||||||
|     }; |     }; | ||||||
|  |  | ||||||
|  | @ -10,14 +10,14 @@ in { | ||||||
|     folders = { |     folders = { | ||||||
|       share = { |       share = { | ||||||
|         enable = lib.mkEnableOption "should the share folder by synced"; |         enable = lib.mkEnableOption "should the share folder by synced"; | ||||||
|  |         calendar = { | ||||||
|  |           enable = lib.mkEnableOption "should the calendar folder be synced"; | ||||||
|  |         }; | ||||||
|       }; |       }; | ||||||
|       leyla = { |       leyla = { | ||||||
|         documents = { |         documents = { | ||||||
|           enable = lib.mkEnableOption "should the documents folder be synced"; |           enable = lib.mkEnableOption "should the documents folder be synced"; | ||||||
|         }; |         }; | ||||||
|         calendar = { |  | ||||||
|           enable = lib.mkEnableOption "should the calendar folder be synced"; |  | ||||||
|         }; |  | ||||||
|         notes = { |         notes = { | ||||||
|           enable = lib.mkEnableOption "should the notes folder by synced"; |           enable = lib.mkEnableOption "should the notes folder by synced"; | ||||||
|         }; |         }; | ||||||
|  | @ -86,26 +86,6 @@ in { | ||||||
|               defiant = lib.mkIf (config.networking.hostName != "defiant") "defiant"; |               defiant = lib.mkIf (config.networking.hostName != "defiant") "defiant"; | ||||||
|               twilight = lib.mkIf (config.networking.hostName != "twilight") "twilight"; |               twilight = lib.mkIf (config.networking.hostName != "twilight") "twilight"; | ||||||
|               horizon = lib.mkIf (config.networking.hostName != "horizon") "horizon"; |               horizon = lib.mkIf (config.networking.hostName != "horizon") "horizon"; | ||||||
|               allDevices = [ |  | ||||||
|                 defiant |  | ||||||
|                 ceder |  | ||||||
|                 coven |  | ||||||
|                 twilight |  | ||||||
|                 horizon |  | ||||||
|                 shale |  | ||||||
|               ]; |  | ||||||
|               leylaDevices = [ |  | ||||||
|                 defiant |  | ||||||
|                 ceder |  | ||||||
|                 coven |  | ||||||
|                 twilight |  | ||||||
|                 horizon |  | ||||||
|               ]; |  | ||||||
|               superNoteTablets = [ |  | ||||||
|                 defiant |  | ||||||
|                 ceder |  | ||||||
|                 shale |  | ||||||
|               ]; |  | ||||||
|             in |             in | ||||||
|               lib.mkMerge [ |               lib.mkMerge [ | ||||||
|                 config.host.sync.folders.extraFolders |                 config.host.sync.folders.extraFolders | ||||||
|  | @ -113,28 +93,48 @@ in { | ||||||
|                   "documents" = { |                   "documents" = { | ||||||
|                     id = "hvrj0-9bm1p"; |                     id = "hvrj0-9bm1p"; | ||||||
|                     path = "${mountDir}/leyla/documents"; |                     path = "${mountDir}/leyla/documents"; | ||||||
|                     devices = leylaDevices; |                     devices = [ | ||||||
|  |                       defiant | ||||||
|  |                       ceder | ||||||
|  |                       coven | ||||||
|  |                       twilight | ||||||
|  |                       horizon | ||||||
|  |                     ]; | ||||||
|                   }; |                   }; | ||||||
|                 }) |                 }) | ||||||
|                 (lib.mkIf config.host.sync.folders.leyla.calendar.enable { |                 (lib.mkIf config.host.sync.folders.share.calendar.enable { | ||||||
|                   "calendar" = { |                   "calendar" = { | ||||||
|                     id = "8oatl-1rv6w"; |                     id = "8oatl-1rv6w"; | ||||||
|                     path = "${mountDir}/leyla/calendar"; |                     path = "${mountDir}/share/calendar"; | ||||||
|                     devices = superNoteTablets; |                     devices = [ | ||||||
|  |                       defiant | ||||||
|  |                       ceder | ||||||
|  |                       shale | ||||||
|  |                     ]; | ||||||
|                   }; |                   }; | ||||||
|                 }) |                 }) | ||||||
|                 (lib.mkIf config.host.sync.folders.leyla.notes.enable { |                 (lib.mkIf config.host.sync.folders.leyla.notes.enable { | ||||||
|                   "notes" = { |                   "notes" = { | ||||||
|                     id = "dwbuv-zffnf"; |                     id = "dwbuv-zffnf"; | ||||||
|                     path = "${mountDir}/leyla/notes"; |                     path = "${mountDir}/leyla/notes"; | ||||||
|                     devices = superNoteTablets; |                     devices = [ | ||||||
|  |                       defiant | ||||||
|  |                       ceder | ||||||
|  |                     ]; | ||||||
|                   }; |                   }; | ||||||
|                 }) |                 }) | ||||||
|                 (lib.mkIf config.host.sync.folders.share.enable { |                 (lib.mkIf config.host.sync.folders.share.enable { | ||||||
|                   "share" = { |                   "share" = { | ||||||
|                     id = "73ot0-cxmkx"; |                     id = "73ot0-cxmkx"; | ||||||
|                     path = "${mountDir}/default/share"; |                     path = "${mountDir}/default/share"; | ||||||
|                     devices = allDevices; |                     devices = [ | ||||||
|  |                       defiant | ||||||
|  |                       ceder | ||||||
|  |                       coven | ||||||
|  |                       twilight | ||||||
|  |                       horizon | ||||||
|  |                       shale | ||||||
|  |                     ]; | ||||||
|                   }; |                   }; | ||||||
|                 }) |                 }) | ||||||
|               ]; |               ]; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue