[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

classic Classic list List threaded Threaded
56 messages Options
123
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list

I think the autosaves should go in the same folder as backups of buffers in that path: relative path from the autosave/backup dir, for untitleds and regular buffers both.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Thu Jun 29, 2017 09:42 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list

I am testing your patch and so far, it seems to work as I asked as long as I don't look into the perspective file :-)


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Thu Jun 29, 2017 09:42 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by jedit-devel mailing list

The problem you are trying to solve: allowing for the user to change autosave directories and using the old one for existing buffers, is not a solution that works for non-untitled buffers.
Personally, I don't think it is an important problem to solve - when the autosave happens, it could read the autosave directory again from the properties, and then use the latest location for subsequent autosaves. Then it would work the same way as it does for non-untitled buffers, and after 30 seconds you don't care what the old value was anymore.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Thu Jun 29, 2017 09:42 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor

There are a lot of public functions you've added to jEdit's API just to make it possible to treat untitled buffers differently from regular ones. I personally think many of them can be removed if we store untitled autosaves the same way as regular autosaves.
But for the ones that can not, you pasted the @since from the original function, and that is not correct. They need to have @since jEdit 5.5pre1 in the javadoc comments.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Thu Jun 29, 2017 09:42 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by jedit-devel mailing list

The default behavior could be set to have the backup location pre-set to something sensible, such as the jEditSettingsDirectory/backups, but that is just a simple value/1-liner we add to the jedit.props file. Then the default behavior won't leave behind autosaves or backups everywhere.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 02, 2017 04:18 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor

Thanx for the $JEDIT_SETTINGS commit, after that I could create my patch to modify the behaviour to match the desired. I also removed the methods that we do need to handle untitled autsaves separately.
Please test the attached patch.

Attachments:


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 02, 2017 04:18 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list

Thank you for following up on this. After a quick read of the .diff I have this comment first. I will apply and test it shortly.

Adding a new jEdit API method "getSettingsOrBackupDirectory()" is wrong and unnecessary.

MiscUtilities.prepareAutosaveDirectory() and prepareBackupDirectory() are separate API functions at the moment, although they are used from different parts of jEdit code, and it allows for a different location to be set for the autosave vs backup directory.

We can add a getBackupDirectory() function to MiscUtilities and then call that from prepareBackupDirectory().

Then every call goes through a single function for getting that location.

We can remove prepareAutosaveDirectory() from MiscUtilities entirely.

And finally, do NOT set any default if the property is empty. "empty property" behavior is to use the SAME directory as the original buffer.

I want to avoid adding new API to jEdit whenever possible.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 09, 2017 08:55 AM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor

We can change every call to prepareAutosaveDirectory to prepareBackupDirectory.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 09, 2017 08:55 AM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by jedit-devel mailing list

Those changes to the savebackupOptionPane should not be necessary.
First of all, the getAutosaveDirecotry() method seems to be doing the expandVariables() anyway, and if you call that method from the right places that need it, you shouldn't need to call miscUtilities.expandVariables() anywhere else.

Second, if I set the backup directory to a variable-prefix value from option pane, there is no reason to expand it before setting it back to properties.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 09, 2017 01:46 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by jedit-devel mailing list

This changes the behavior of jEdit:

@@ -1933,8 +1927,7 @@
{
path = editPane.getBuffer().getDirectory();
} else {
- File autosaveDir = MiscUtilities.prepareAutosaveDirectory(System.getProperty("user.home"), true);
- path = autosaveDir.getPath();
+ path = (new File(jEdit.getBackupOrSettingsDirectory())).getPath();
}
VFS vfs = VFSManager.getVFSForPath(path);

The idea behind this code was to pass user.home as the "default location" in case the buffer.getDirectory() pointed to a read only file system. If prepareBackupDirectory() doesn't behave that way, it should.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 09, 2017 01:46 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor

I made changes, according to your comments. Please review.

Attachments:


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sun Jul 09, 2017 01:46 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list

Very nice! Testing now.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: pending-remind
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Fri Jul 14, 2017 02:01 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor
  • status: pending-remind --> closed-accepted
  • Comment:

Committed revision 24725.
Thank you for your very fine work! It is a pleasure working with you.
I hope you can find other things about jEdit you wanna work on :-)


[patches:#596] #501 Auto-save untitled buffers - patch

Status: closed-accepted
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Fri Jul 14, 2017 02:01 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor

I am glad that this feature will appear in the next release. Your guidance was very helpfull. I think I will ask Andrew for a post on webup8 once the debs are available.


[patches:#596] #501 Auto-save untitled buffers - patch

Status: closed-accepted
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Fri Jul 14, 2017 02:42 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list
In reply to this post by Hrotkó Gábor

Hmm. It doesn't seem to work for me. I have the "Backup, Autosave directory" set to: /Users/eberry/Library/jEdit/backups.

I opened a new untitled buffer, from while editing a file that is on my Desktop. I see a file #Untitled-1# on my desktop, and a back up in /Users/eberry/Library/jEdit/backups/Users/eberry/Desktop.

From my understanding, I should only see the backup file in the backups directory, correct? May be an issue specific to Macs?

Now I have 2 copies of the untitled buffer on my file system, and one of them in the place I didn't want it to be (on my Desktop - this could have been Dropbox, or Google Drive, or any other file sharing folder).


[patches:#596] #501 Auto-save untitled buffers - patch

Status: closed-accepted
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Sat Jul 15, 2017 08:40 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
Reply | Threaded
Open this post in threaded view
|

[ jEdit-devel ] [jedit:patches] Re: #596 #501 Auto-save untitled buffers - patch

jedit-devel mailing list

Nevermind, it looks like it was an artifact from a previous Untitled buffer, the content was old, and the file didn't delete itself when I closed the buffer in jEdit.

Closing all Untitled buffers, and manually deleting them from the file system, then trying again from scratch shows that the Untitled buffers don't get persisted in the same directory of the current-buffer.

Nice work!


[patches:#596] #501 Auto-save untitled buffers - patch

Status: closed-accepted
Group:
Labels: untitled autosave
Created: Fri Feb 17, 2017 05:34 PM UTC by Hrotkó Gábor
Last Updated: Mon Jul 17, 2017 05:58 PM UTC
Owner: Alan Ezust
Attachments:

I created a patch for the feature request: "#501 Auto-save untitled buffers".
Altough the settings "Autosave untitled buffers" exists, but not working like described in the feature request.
My patch extends this feature, when "Autosave untitled buffers" checked (default):
- the untitled buffers will be autosaved when closing jedit, without a question prompt
- the autosave for an untitled buffer saved to <jedit_settings_dir>/autosave, and reloaded after a restart (the state persisted to the perspective.xml)
- closing an untitled buffer by hand removes the autosave file

Tested on windows7 and linux also.
The patch is against revision 24609.
Please review.
Thanks!


Sent from sourceforge.net because [hidden email] is subscribed to https://sourceforge.net/p/jedit/patches/

To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Developers' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-devel
123