Dotan Cohen wrote:
But there is exactly my point, settings, profiles and caches go in
hidden directories, data does not. In my view settings are more or
less expandable - sure you do not want to loose them easily, but if
you do you can re-create them fairly easily. Data on the other hand is
much more valuable.


Are your email messages data? Where does Evolution store them?

Files that are meant to be opened from within a particular application
should not be visible in the file manager. If Zim notebooks were
single files as opposed to folders with many files inside, and these
single files could be clicked on then opened with Zim, then I would
understand the reasoning for keeping them visible. But as it stands,
the user has no reason to poke around in the Zim folder.
I agree with Jaap about data directory being not hidden.

One more reason, which partially answers Dotan's point:
- zim pages are plain text files, which can be manipulated by other programs or scripts.

See one unusual test case attached: a shell script that adds a list item to current days page. Usage:
$ ./my.log "Hi, this is a test"

--
Emilis Dambauskas

emili...@gmail.com
gsm: +370-686-07732
irc: emilis_i...@irc.freenode.net
http://emilis.info

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GAT/CC/MC/O dpu(-) s:- a- C++ UBLHS++ P(+) L+++ E--- W+++$ N+ o-- K? !w O? M-@ V? 
PS+(--) PE Y+>++ PGP t- 5? X+@ R- !tv b+ DI++++ D G e++ h---- r+++ y++++
------END GEEK CODE BLOCK------

#!/bin/sh

### CONSTANTS ###

NOTEBOOK_DIR='/home/emilis/zim'

### FUNCTIONS ###

# Creates an empty zim file for the date:
create_zim_file() {
    dir_name=`dirname $file_name`
    echo "Creating directory $dir_name"
    if ! test -d $dir_name; then
        mkdir -p $dir_name
    fi

    touch $file_name

    header="Content-Type: text/x-zim-wiki\nWiki-Format: zim 0.26\nCreation-Date: `date`\nModification-Date: `date`"
    header="$header\n\n====== `date +%F` ======\n\n"

    echo $header >> $file_name
}

### PROGRAM ###

file_name="$NOTEBOOK_DIR/Date/`date +%Y`/`date +%m`/`date +%d`.txt"
echo $file_name;

if ! test -f $file_name; then
    create_zim_file
fi

echo "* `date +%T` $@" >> $file_name
_______________________________________________
Mailing list: https://launchpad.net/~zim-wiki
Post to     : zim-wiki@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zim-wiki
More help   : https://help.launchpad.net/ListHelp

Reply via email to