On 23/11/2016 01:11, Enrico Forestieri wrote:
On Tue, Nov 22, 2016 at 11:59:37PM +0100, Tommaso Cucinotta wrote:
There's a couple of TODOs left:
1. versioning of the preferences file, I don't know much in this area, the
patch adds a couple of preferences options, what else is needed?
Have a look at c2a18fc1 to get an idea.
Looks straightforward, so I just came up with the attached patch, anyone
willing to review before pushing ?
Thanks,
T.
>From cc653feb605bcbfdbbad436f23547dc0728a175a Mon Sep 17 00:00:00 2001
From: Tommaso Cucinotta <tomm...@lyx.org>
Date: Fri, 25 Nov 2016 23:33:08 +0100
Subject: [PATCH] Bump up RC fileformat after [244de5d2/lyxgit] for the new
'needauth' options.
Addressing #10481.
---
lib/configure.py | 2 +-
lib/scripts/prefs2prefs_prefs.py | 7 ++++++-
src/LyXRC.cpp | 2 +-
3 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/lib/configure.py b/lib/configure.py
index b282a284..fb1abd35 100644
--- a/lib/configure.py
+++ b/lib/configure.py
@@ -1551,7 +1551,7 @@ if __name__ == '__main__':
lyx_check_config = True
lyx_kpsewhich = True
outfile = 'lyxrc.defaults'
- lyxrc_fileformat = 19
+ lyxrc_fileformat = 20
rc_entries = ''
lyx_keep_temps = False
version_suffix = ''
diff --git a/lib/scripts/prefs2prefs_prefs.py b/lib/scripts/prefs2prefs_prefs.py
index 85fa90e0..ff318369 100644
--- a/lib/scripts/prefs2prefs_prefs.py
+++ b/lib/scripts/prefs2prefs_prefs.py
@@ -80,6 +80,10 @@
# Incremented to format 19, by rgh
# remove print support
+# Incremented to format 20, by tommaso
+# Add options to forbid/ignore 'needauth' option
+# No conversion necessary.
+
# NOTE: The format should also be updated in LYXRC.cpp and
# in configure.py.
@@ -375,5 +379,6 @@ conversions = [
[ 16, [remove_force_paint_single_char]],
[ 17, [remove_rtl]],
[ 18, []],
- [ 19, [remove_print_support]]
+ [ 19, [remove_print_support]],
+ [ 20, []]
]
diff --git a/src/LyXRC.cpp b/src/LyXRC.cpp
index 355e0651..587e1e7c 100644
--- a/src/LyXRC.cpp
+++ b/src/LyXRC.cpp
@@ -59,7 +59,7 @@ namespace {
// The format should also be updated in configure.py, and conversion code
// should be added to prefs2prefs_prefs.py.
-static unsigned int const LYXRC_FILEFORMAT = 19; // rgh: remove print support
+static unsigned int const LYXRC_FILEFORMAT = 20; // tommaso: 'needauth' options
// when adding something to this array keep it sorted!
LexerKeyword lyxrcTags[] = {
--
2.9.3