Add gio_unsafe_save_backup hidden pref (patch by Lex Trotman,
thanks). git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@5430 ea778897-0a13-0410-b9d1-a72fbfd435f5
This commit is contained in:
parent
7dbb4359f4
commit
3a3d8815a3
@ -11,6 +11,10 @@
|
||||
* src/interface.c, doc/geany.txt, doc/geany.html, geany.glade:
|
||||
Don't use 'Enable' in pref labels when unnecessary.
|
||||
Rename XML/HTML tag autocompletion -> auto-closing.
|
||||
* src/keyfile.c, src/document.c, src/document.h, doc/geany.txt,
|
||||
doc/geany.html:
|
||||
Add gio_unsafe_save_backup hidden pref (patch by Lex Trotman,
|
||||
thanks).
|
||||
|
||||
|
||||
2010-11-22 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
||||
|
@ -4959,6 +4959,11 @@ The better approach would be to ensure your
|
||||
disk won't run out of free space.</td>
|
||||
<td>false</td>
|
||||
</tr>
|
||||
<tr><td>gio_unsafe_save_backup</td>
|
||||
<td>Make a backup when using GIO unsafe file
|
||||
saving. Backup is named <cite>filename~</cite>.</td>
|
||||
<td>false</td>
|
||||
</tr>
|
||||
<tr><td><strong>Search related</strong></td>
|
||||
<td> </td>
|
||||
<td> </td>
|
||||
@ -6367,7 +6372,7 @@ USE OR PERFORMANCE OF THIS SOFTWARE.</p>
|
||||
<div class="footer">
|
||||
<hr class="footer" />
|
||||
<a class="reference" href="geany.txt">View document source</a>.
|
||||
Generated on: 2010-11-23 13:39 UTC.
|
||||
Generated on: 2010-11-23 16:18 UTC.
|
||||
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
|
||||
|
||||
</div>
|
||||
|
@ -4225,6 +4225,8 @@ use_safe_file_saving Defines the mode how Geany saves files to f
|
||||
break things seriously.
|
||||
The better approach would be to ensure your
|
||||
disk won't run out of free space.
|
||||
gio_unsafe_save_backup Make a backup when using GIO unsafe file false
|
||||
saving. Backup is named `filename~`.
|
||||
**Search related**
|
||||
find_selection_type See `Find selection`_. 0
|
||||
**Build Menu related**
|
||||
|
@ -1721,7 +1721,7 @@ static gchar *write_data_to_disk(const gchar *locale_filename,
|
||||
|
||||
/* Use GIO API to save file (GVFS-safe) */
|
||||
fp = g_file_new_for_path(locale_filename);
|
||||
g_file_replace_contents(fp, data, len, NULL, FALSE,
|
||||
g_file_replace_contents(fp, data, len, NULL, file_prefs.gio_unsafe_save_backup,
|
||||
G_FILE_CREATE_NONE, NULL, NULL, &error);
|
||||
g_object_unref(fp);
|
||||
#else
|
||||
|
@ -60,6 +60,7 @@ typedef struct GeanyFilePrefs
|
||||
gboolean cmdline_new_files; /* New file if command-line filename doesn't exist */
|
||||
gboolean use_safe_file_saving;
|
||||
gboolean ensure_convert_new_lines;
|
||||
gboolean gio_unsafe_save_backup;
|
||||
}
|
||||
GeanyFilePrefs;
|
||||
|
||||
|
@ -189,6 +189,8 @@ static void init_pref_groups(void)
|
||||
"complete_snippets_whilst_editing", FALSE);
|
||||
stash_group_add_boolean(group, &file_prefs.use_safe_file_saving,
|
||||
"use_safe_file_saving", FALSE);
|
||||
stash_group_add_boolean(group, &file_prefs.gio_unsafe_save_backup,
|
||||
"gio_unsafe_save_backup", FALSE);
|
||||
/* for backwards-compatibility */
|
||||
stash_group_add_integer(group, &editor_prefs.indentation->hard_tab_width,
|
||||
"indent_hard_tab_width", 8);
|
||||
|
Loading…
x
Reference in New Issue
Block a user