summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorArun Isaac2022-06-26 23:39:09 +0530
committerArun Isaac2022-06-27 00:19:51 +0530
commit76991c195740d2edee0a1887b4850e438d8e83d2 (patch)
treed4672cf94f4d03b4aadc765e5bf6f4010c99ff83 /bin
parentef47614b81052f2a2758ad26c194a44a8ce441c6 (diff)
downloadtissue-76991c195740d2edee0a1887b4850e438d8e83d2.tar.gz
tissue-76991c195740d2edee0a1887b4850e438d8e83d2.tar.lz
tissue-76991c195740d2edee0a1887b4850e438d8e83d2.zip
issue: Replace issues thunk with read-gemtext-issue reader.
* tissue/issue.scm (%issue-files): Delete parameter. (issues): Delete function. (read-gemtext-issue): New public function. (file-modification-table-for-current-repository): New function. * bin/tissue (main): Do not parameterize %issue-files.
Diffstat (limited to 'bin')
-rwxr-xr-xbin/tissue19
1 files changed, 9 insertions, 10 deletions
diff --git a/bin/tissue b/bin/tissue
index 63b5682..94ab5d6 100755
--- a/bin/tissue
+++ b/bin/tissue
@@ -93,14 +93,6 @@ to run tissue."
(match (command-line)
((program _ ...) program)))
-(define (print-document document)
- "Print DOCUMENT, an <issue> or <document> object."
- ((cond
- ((issue? document) print-issue)
- ((doc:document? document) doc:print-document)
- (else (raise (unknown-document-type-violation document))))
- document))
-
(define (print-issue issue)
"Print ISSUE."
(let ((number-of-posts (length (issue-posts issue))))
@@ -174,6 +166,14 @@ to run tissue."
(newline)
(newline)))
+(define (print-document document)
+ "Print DOCUMENT, an <issue> or <document> object."
+ ((cond
+ ((issue? document) print-issue)
+ ((doc:document? document) doc:print-document)
+ (else (raise (unknown-document-type-violation document))))
+ document))
+
(define (alist->document alist)
"Convert ALIST to an <issue> or <document> object."
((case (assq-ref alist 'type)
@@ -396,8 +396,7 @@ DB."
(exit #f)))
(call-with-current-directory (git-top-level)
(lambda ()
- (parameterize ((%issue-files (tissue-configuration-issue-files (load-config)))
- (%aliases (tissue-configuration-aliases (load-config))))
+ (parameterize ((%aliases (tissue-configuration-aliases (load-config))))
;; Create hidden tissue directory unless it exists.
(unless (file-exists? %state-directory)
(mkdir %state-directory))