index.db depends on how zim has been invoked, on one and the same host.
Attached is a proof with an example zim book "~/info/Info_Zim/ScratchInfo".
Bad Case a)
===========
1) rm ~/info/Info_Zim/ScratchInfo/.zim/* # start with defined conditions
2) Launch zim via an own XFCE launcher or via the Desktop Application Menu.
Keep in mind that the whole environment is minimum, shell startup
scripts are not sourced and you just have no shell etc.
3) Within zim get access to he book ScratchInfo via
File - Open Another Notebook # add it if needed, then open it
I don't know if the location of zim books does matter, it should not.
4) # Pick Task List from Tool bar to enforce the build of a new index
# leave zim now
5) create an sql dump of index.db
cd ~/info/Info_Zim/ScratchInfo/.zim
mkdir -p KeepMe/01
sqlite3 index.db .dump >KeepMe/01/dump.sql # this file is broken
less -NS KeepMe/01/dump.sql
21 INSERT INTO "pages" VALUES(1,'','',0,0,1,NULL,NULL,NULL,NULL,1.42757454824159431454e+09);
22 INSERT INTO "pages" VALUES(2,'Home','^S^Z^X^P^A ^A ',1,1,0,NULL,NULL,NULL,1.42635246455724644656e+09,NULL);
23 INSERT INTO "pages" VALUES(3,'tmp','^_^XESC^A ^A ',1,1,0,NULL,NULL,NULL,1.42757454820559430124e+09,NULL);
Good Case b)
============
1) rm ~/info/Info_Zim/ScratchInfo/.zim/* # again, start with defined conditions
2) Launch zim via xterm or ssh -X
zim --standalone ~/info/Info_Zim/ScratchInfo/
3) # we already are within the book, skip this step
4) # Tool bar: Task List
# this will enforce a new index to be created
# leave zim now
5) create an sql dump of index.db
cd ~/info/Info_Zim/ScratchInfo/.zim
mkdir -p KeepMe/02
sqlite3 index.db .dump >KeepMe/02/dump.sql # this file looks good
less -NS KeepMe/02/dump.sql
22 INSERT INTO "pages" VALUES(1,'','',0,0,1,NULL,NULL,NULL,NULL,1.42757454824159431454e+09);
23 INSERT INTO "pages" VALUES(2,'tmp','tmp',1,1,0,NULL,NULL,NULL,1.42757454820559430124e+09,NULL);
24 INSERT INTO "pages" VALUES(3,'Home','home',1,1,0,NULL,NULL,NULL,1.42635246455724644656e+09,NULL);
25 INSERT INTO "pages" VALUES(4,'Inkscape','inkscape',1,1,1,NULL,NULL,NULL,1.42670902619396615029e+09,1.4282495210700762272e+09);
You can work with the zim book with Bad Case a) as well as with Good Case b),
But if you decide to switch between the 2 different launch methods then the index is
totally broken and useless, the complete index pane is a whole mess.
I do need access to the zim book from several hosts and now I know a work around:
Just start local work also via xterm and enjoy. Local XFCE launcher will give
Bad Case a).
You can also build a launcher with a wrapper like:
ssh -X localhost '$HOME/info/bin/StartZim.sh'
where the wrapper just holds:
Concrete hint:
index.db depends on how zim has been invoked, on one and the same host. Info_Zim/ ScratchInfo" .
Attached is a proof with an example zim book "~/info/
Bad Case a) Info_Zim/ ScratchInfo/ .zim/* # start with defined conditions Info_Zim/ ScratchInfo/ .zim 1,'','' ,0,0,1, NULL,NULL, NULL,NULL, 1.4275745482415 9431454e+ 09); 2,'Home' ,'^S^Z^ X^P^A ^A ',1,1,0, NULL,NULL, NULL,1. 426352464557246 44656e+ 09,NULL) ; 3,'tmp' ,'^_^XESC^ A ^A ',1,1,0, NULL,NULL, NULL,1. 427574548205594 30124e+ 09,NULL) ;
===========
1) rm ~/info/
2) Launch zim via an own XFCE launcher or via the Desktop Application Menu.
Keep in mind that the whole environment is minimum, shell startup
scripts are not sourced and you just have no shell etc.
3) Within zim get access to he book ScratchInfo via
File - Open Another Notebook # add it if needed, then open it
I don't know if the location of zim books does matter, it should not.
4) # Pick Task List from Tool bar to enforce the build of a new index
# leave zim now
5) create an sql dump of index.db
cd ~/info/
mkdir -p KeepMe/01
sqlite3 index.db .dump >KeepMe/01/dump.sql # this file is broken
less -NS KeepMe/01/dump.sql
21 INSERT INTO "pages" VALUES(
22 INSERT INTO "pages" VALUES(
23 INSERT INTO "pages" VALUES(
Good Case b) Info_Zim/ ScratchInfo/ .zim/* # again, start with defined conditions Info_Zim/ ScratchInfo/ Info_Zim/ ScratchInfo/ .zim 1,'','' ,0,0,1, NULL,NULL, NULL,NULL, 1.4275745482415 9431454e+ 09); 2,'tmp' ,'tmp', 1,1,0,NULL, NULL,NULL, 1.4275745482055 9430124e+ 09,NULL) ; 3,'Home' ,'home' ,1,1,0, NULL,NULL, NULL,1. 426352464557246 44656e+ 09,NULL) ; 4,'Inkscape' ,'inkscape' ,1,1,1, NULL,NULL, NULL,1. 426709026193966 15029e+ 09,1.4282495210 700762272e+ 09);
============
1) rm ~/info/
2) Launch zim via xterm or ssh -X
zim --standalone ~/info/
3) # we already are within the book, skip this step
4) # Tool bar: Task List
# this will enforce a new index to be created
# leave zim now
5) create an sql dump of index.db
cd ~/info/
mkdir -p KeepMe/02
sqlite3 index.db .dump >KeepMe/02/dump.sql # this file looks good
less -NS KeepMe/02/dump.sql
22 INSERT INTO "pages" VALUES(
23 INSERT INTO "pages" VALUES(
24 INSERT INTO "pages" VALUES(
25 INSERT INTO "pages" VALUES(
You can work with the zim book with Bad Case a) as well as with Good Case b), info/bin/ StartZim. sh'
But if you decide to switch between the 2 different launch methods then the index is
totally broken and useless, the complete index pane is a whole mess.
I do need access to the zim book from several hosts and now I know a work around:
Just start local work also via xterm and enjoy. Local XFCE launcher will give
Bad Case a).
You can also build a launcher with a wrapper like:
ssh -X localhost '$HOME/
where the wrapper just holds:
#!/bin/bash
zim --standalone 2>&1 >/tmp/Zim_AW.log
This way you also can save the error messages.
Best regards, Andreas