New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to backup settings automatically #317

Open
mateddy opened this Issue Nov 29, 2016 · 10 comments

Comments

Projects
None yet
7 participants
@mateddy

mateddy commented Nov 29, 2016

I made some changes in preferences (e.g. add an extra file in sync-settings), and then close and reopen Atom.

sync-settings: Latest backup is already applied.

Only when I manually edit anyfile in my gist, the sync setting dialog shows on startup.
I know I can manually run "Sync Settings: Backup", but isn't it supposed to be done automatically?

@dirk-thomas

This comment has been minimized.

Show comment
Hide comment
@dirk-thomas

dirk-thomas Nov 29, 2016

Member

The backup command is triggered manually. Only the restore is being triggered automatically.

Member

dirk-thomas commented Nov 29, 2016

The backup command is triggered manually. Only the restore is being triggered automatically.

@mateddy

This comment has been minimized.

Show comment
Hide comment
@mateddy

mateddy Nov 29, 2016

Should there be such an option?

mateddy commented Nov 29, 2016

Should there be such an option?

@dirk-thomas

This comment has been minimized.

Show comment
Hide comment
@dirk-thomas

dirk-thomas Nov 29, 2016

Member

It probably depends on your use case. If you use automatic backups with multiple computers you will likely run into problems that after backing up from A the automatic backup of B would overwrite the previous changes. Therefore it is currently not done automatically. But I can see in a single machine setup that it would be convenient. Maybe someone can work on a pull request for that.

Member

dirk-thomas commented Nov 29, 2016

It probably depends on your use case. If you use automatic backups with multiple computers you will likely run into problems that after backing up from A the automatic backup of B would overwrite the previous changes. Therefore it is currently not done automatically. But I can see in a single machine setup that it would be convenient. Maybe someone can work on a pull request for that.

@dirk-thomas dirk-thomas changed the title from Sync-setting did not sync to Option to backup settings automatically Nov 29, 2016

@cybermancy

This comment has been minimized.

Show comment
Hide comment
@cybermancy

cybermancy Nov 30, 2016

Would also love this feature.

cybermancy commented Nov 30, 2016

Would also love this feature.

@mateddy

This comment has been minimized.

Show comment
Hide comment
@mateddy

mateddy Nov 30, 2016

@dirk-thomas Agreed, so I think it is better to:
if (setting is changed)
alert("Setting changed, backup, restore or diff?");

See if I can code something this weekend.

mateddy commented Nov 30, 2016

@dirk-thomas Agreed, so I think it is better to:
if (setting is changed)
alert("Setting changed, backup, restore or diff?");

See if I can code something this weekend.

@cybermancy

This comment has been minimized.

Show comment
Hide comment
@cybermancy

cybermancy Dec 6, 2016

@mateddy I think this is a good way to approach the problem. Consider also putting in a checkbox to allow automated backups without a prompt though, for single PC users.

cybermancy commented Dec 6, 2016

@mateddy I think this is a good way to approach the problem. Consider also putting in a checkbox to allow automated backups without a prompt though, for single PC users.

@ivanaugustobd

This comment has been minimized.

Show comment
Hide comment
@ivanaugustobd

ivanaugustobd Mar 30, 2017

Maybe something (optional) like this: when open Atom, automatically restore the backup and immediately after make a new backup; then when some change occur (or if is possible detect "close Atom" event), it do a new backup silently.

So when you open Atom in other computer it will do this again, syncing settings without need to prompt anything and reducing chances to accidental overwrite (what I believe will only occur if you open Atom simultaneously in other computer after make some change in first opened instance) 😄

ivanaugustobd commented Mar 30, 2017

Maybe something (optional) like this: when open Atom, automatically restore the backup and immediately after make a new backup; then when some change occur (or if is possible detect "close Atom" event), it do a new backup silently.

So when you open Atom in other computer it will do this again, syncing settings without need to prompt anything and reducing chances to accidental overwrite (what I believe will only occur if you open Atom simultaneously in other computer after make some change in first opened instance) 😄

chibicode added a commit to chibicode/sync-settings that referenced this issue Jun 24, 2017

@chibicode

This comment has been minimized.

Show comment
Hide comment
@chibicode

chibicode Jun 24, 2017

Contributor

I also got confused as well. I made a PR to README.md to clarify this point: #369

Contributor

chibicode commented Jun 24, 2017

I also got confused as well. I made a PR to README.md to clarify this point: #369

@Salamandar

This comment has been minimized.

Show comment
Hide comment
@Salamandar

Salamandar Oct 2, 2017

Hi, Github+Gist supports merging, right ?
So if two settings exist (local and gist), why not allow the user to manually merge on auto-restore ?
And only if the merge is resolved, apply + backup the merge.

Salamandar commented Oct 2, 2017

Hi, Github+Gist supports merging, right ?
So if two settings exist (local and gist), why not allow the user to manually merge on auto-restore ?
And only if the merge is resolved, apply + backup the merge.

@tobiasvl

This comment has been minimized.

Show comment
Hide comment
@tobiasvl

tobiasvl Aug 13, 2018

Any movement on this? I really want this feature.

I won't lie and say I understand everything in the referenced PR, but as long as the option to automatically trigger backup defaults to off, this shouldn't be too harmful. When setting up a new computer, install this package, restore from backup, turn the option on (or maybe it got turned on by the restored settings?) and you should be fine.

If one of the computers is offline and thus can't backup, you might of course run into problems later if you change any settings there. (Although I already encounter issues multiple times a week because I forget to backup at work or at home, hehe.)

But as long as automatic backup being on and backup failing triggers a visible error (or, if it has to be, a warning), that should be OK I think.

If this doesn't get fixed, I'm tempted to learn enough Atom to write a package that uses Git to sync settings, not just Gist, so it can error out when restoring from backup isn't a simple fast-forward merge. I can't live without a settings sync package, but it's also pretty aggravating that I have to backup manually, and that backup/restore with a conflict between local and remote doesn't merge in any clean way. (The number of times I've had to scroll through the history of my syncing Gist to find out what package is missing from my current computer because of this...)

tobiasvl commented Aug 13, 2018

Any movement on this? I really want this feature.

I won't lie and say I understand everything in the referenced PR, but as long as the option to automatically trigger backup defaults to off, this shouldn't be too harmful. When setting up a new computer, install this package, restore from backup, turn the option on (or maybe it got turned on by the restored settings?) and you should be fine.

If one of the computers is offline and thus can't backup, you might of course run into problems later if you change any settings there. (Although I already encounter issues multiple times a week because I forget to backup at work or at home, hehe.)

But as long as automatic backup being on and backup failing triggers a visible error (or, if it has to be, a warning), that should be OK I think.

If this doesn't get fixed, I'm tempted to learn enough Atom to write a package that uses Git to sync settings, not just Gist, so it can error out when restoring from backup isn't a simple fast-forward merge. I can't live without a settings sync package, but it's also pretty aggravating that I have to backup manually, and that backup/restore with a conflict between local and remote doesn't merge in any clean way. (The number of times I've had to scroll through the history of my syncing Gist to find out what package is missing from my current computer because of this...)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment