Feature request: Auto rule backup

Talk, speculate, discuss, pontificate. As long as it pertains to Hazel.

Moderators: Mr_Noodle, Moderators

Feature request: Auto rule backup Wed Dec 02, 2020 9:51 am • by matthewp
I would like to be able to point hazel at a folder to back up all rules on a periodic basis. All rules would be backed up regardless of whether their folders are synced or not.

Importing a backup allows you to map folders in the backup to real folders on the machine.

This is to allow quick and easy restoration of rules when installing Hazel on a new machine. I've just had to do that and while I used to be more diligent it had been a very long time since I exported all my hazel rules. I recreated what wasn't synced rather than trying to dig through backups.
matthewp
 
Posts: 18
Joined: Sun Jan 24, 2016 5:51 am

Re: Feature request: Auto rule backup Wed Dec 02, 2020 10:57 am • by Mr_Noodle
I think the better approach is to do general backups. Spending time on such a feature would be a waste when something like Time Machine does it better, and is not limited to Hazel. I may consider an easy way to restore from backups that you point Hazel to, though.
Mr_Noodle
Site Admin
 
Posts: 9709
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Feature request: Auto rule backup Wed Dec 02, 2020 11:29 pm • by luomat
What about a way to say "Sync ALL of my rules to this folder" ?

So, for example, if I chose ~/Documents/Hazel/MacBookPro/ as the "main" folder, then my rules for "~/Downloads/" would automatically be added to ~/Documents/Hazel/MacBookPro/Downloads/

Making a separate sync file for each folder is enough friction that someone might not do it, but if there was a "Default Main Folder" that would remove that friction.

I have no idea how easy or difficult that would be. Just an idea.
luomat
 
Posts: 76
Joined: Wed Mar 10, 2010 3:57 pm

Re: Feature request: Auto rule backup Thu Dec 03, 2020 9:58 am • by Mr_Noodle
Would this be for backups or something else? Again, for backups, a more general solution would work much better. Your rules files are already under Application Support so as long as that is part of your backup plan, you should be set.
Mr_Noodle
Site Admin
 
Posts: 9709
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Feature request: Auto rule backup Thu Dec 03, 2020 9:15 pm • by luomat
Well, for me it would be both backup and syncing. I tend to want the same rules everywhere, and and having them all available everywhere would make that a bit easier.
luomat
 
Posts: 76
Joined: Wed Mar 10, 2010 3:57 pm

Re: Feature request: Auto rule backup Fri Dec 04, 2020 11:53 am • by Mr_Noodle
I'd say that's a different issue. Not sure how common that is but will think about it.
Mr_Noodle
Site Admin
 
Posts: 9709
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Feature request: Auto rule backup Fri Dec 04, 2020 2:40 pm • by luomat
Completely understood. I realize this is something that I'd use, but even I would have to admit that I can imagine not a lot of others are out there like me.
luomat
 
Posts: 76
Joined: Wed Mar 10, 2010 3:57 pm

Re: Feature request: Auto rule backup Sat Dec 26, 2020 9:35 pm • by matthewp
I think what I'm ultimately looking for is simply a timesaver when setting up a new Mac. I recently did this (opting to build from scratch rather than migrate) and for the utilities that had some native iCloud functionality after a few clicks everything was there from the start. In fact I did not have to access my backup at all except for Hazel and Streamdeck. With Hazel, in the end, I ultimately didn't bother and just rebuilt a few rules for those few folders I didn't happen to sync the rules for. In the case of both Hazel and Streamdeck I didn't easily find guidance on how to extract the config files from the library folder structure and restore, I had to do a bit of snooping on my own. It didn't help that at least for streamdeck, they were in hidden folders also. It sure would be great if installing Hazel on a new Mac would pull in the very last version of your rules from iCloud Drive/Dropbox and all you had to do was map them to folders (creating if they didn't exist or if they did but weren't obvious to Hazel). Due app was one that did this extremely well.
matthewp
 
Posts: 18
Joined: Sun Jan 24, 2016 5:51 am

Re: Feature request: Auto rule backup Sat Dec 26, 2020 10:55 pm • by luomat
matthewp wrote:Due app was one that did this extremely well.


I would imagine that that challenge is that Hazel can have multiple configurations on each computer, whereas Due has one main centralized repository that would be the same on any device you connect to it.

If I have different rules on my MacBook vs my iMac vs my Mac mini, how does Hazel know which to restore from?

I suppose one option would be like when you connect a new iPhone to iCloud and it shows you both iPad and iPhone backups and says "Which of these do you want to use?"

(This bit is off-topic, but… Stream Deck has a feature to make a backup of its configuration which can then be used to setup a new Stream Deck or on a new computer. Go to Preferences » Profiles and click the 'v' shape near the bottom and there is an option to 'Backup All' and from there you can either create a backup or restore from a backup.)
luomat
 
Posts: 76
Joined: Wed Mar 10, 2010 3:57 pm


Return to Open Discussion