aboutsummaryrefslogtreecommitdiff
path: root/lesana/command.py
blob: bd6ecabc30b59ef3e6dc1a01dd2f70400183e8e5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import gadona
#from .collection import Collection, Entry
from . import Collection, Entry


class New(gadona.Command):
    name = 'new'
    arguments = [
        (['--collection', '-c'], dict(
            help='The collection to work on (default .)'
            )),
        ]

    def main(self):
        collection = Collection()
        new_entry = Entry(collection)
        collection.save_entries(new_entry)
        print(new_entry.fname)