From 658a7c2f246e6adaa37c8e27d547e0b26ee46150 Mon Sep 17 00:00:00 2001 From: Thanos Apollo Date: Wed, 29 Nov 2023 08:05:25 +0200 Subject: Update gnosis-init & test buffer for testing purposes --- gnosis.el | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'gnosis.el') diff --git a/gnosis.el b/gnosis.el index 84e33bb..18c657b 100644 --- a/gnosis.el +++ b/gnosis.el @@ -137,17 +137,22 @@ use it like this: (interactive) (with-current-buffer (switch-to-buffer (get-buffer-create "*gnosis*")) - (setq-local minibuffer-history nil) + (read-only-mode 0) + (erase-buffer) (gnosis--display-question 1) (gnosis-review 1) (gnosis-mode))) (defun gnosis-init () "Create notes content table." - (gnosis--create-table 'notes '([(question_id integer :primary-key) - type - question - choices + (interactive) + (condition-case nil + (gnosis--drop-table 'notes) + (error (message "No NOTES table to drop, recreating new one."))) + (gnosis--create-table 'notes '([(id integer :primary-key) + (type text) + (main text) + options answer tags rev_log -- cgit v1.2.3