as an alias to a user-provided script.
- see timeline ops above
- see hashtag and channels above
- [x] d | download
- - [ ] u | upload
+ - [x] u | upload
- calls user-configured command to upload user's own feed file to their server
Looks like a better CLI parser than "racket/cmdline": https://docs.racket-lang.org/natural-cli/
But it is no longer necessary now that I've figured out how to chain (command-line ..) calls.
(define pkg-desc
"twtxt client")
(define version
- "0.8.0")
+ "0.9.0")
(define pkg-authors
'("Siraaj Khandkar <siraaj@khandkar.net>"))
(define deps
"and <command> is one of"
"r, read i : Read the timeline."
"d, download : Download the timeline."
+ "u, upload : Upload your twtxt file (alias to execute ~/.tt/upload)."
""
#:args (command . args)
(start-logger log-level)
(current-http-client/user-agent user-agent))
(timeline-download num_workers (file->feeds filename))
))]
+ [(or "u" "upload")
+ (command-line
+ #:program
+ "tt upload"
+ #:args ()
+ (if (system (path->string (expand-user-path "~/.tt/upload")))
+ (exit 0)
+ (exit 1)))]
[(or "r" "read")
(let ([out-format 'multi-line]
[order 'old->new])