mirror of
https://codeberg.org/cage/tinmop/
synced 2024-12-22 23:47:56 +01:00
- fixed welcomebot and moved to a new directory "scripts";
Also export some symbols that this script uses, from others packages.
This commit is contained in:
parent
05e2f0164e
commit
6c590dbf1a
@ -24,15 +24,14 @@
|
||||
(define-constant +table-id+ "welcome-minimum-id" :test #'string=)
|
||||
|
||||
(defparameter *welcome-message-template* "Hi ~s!~%Enjoy the fediverse!"
|
||||
:test #'string=
|
||||
:documentation "The welcome message, the '~s' is replaced with the display-name
|
||||
"The welcome message, the '~s' is replaced with the display-name
|
||||
of the welcomed user")
|
||||
|
||||
(defun make-table-last-id ()
|
||||
(db-utils:query-low-level (strcat (db::prepare-table +table-id+
|
||||
(db-utils:query-low-level (strcat (db:prepare-table +table-id+
|
||||
:autogenerated-id-p nil)
|
||||
" id TEXT"
|
||||
db::+make-close+)))
|
||||
db:+make-close+)))
|
||||
|
||||
(defun dump-minimum-id (minimum-id)
|
||||
(db-utils:query (db-utils:make-insert :welcome-minimum-id (:id) (minimum-id))))
|
||||
@ -57,9 +56,9 @@ of the welcomed user")
|
||||
(let ((minimum-id (minimum-id)))
|
||||
(assert (or (stringp minimum-id)
|
||||
(null minimum-id)))
|
||||
(let* ((toots (api-client::sort-id< (api-client:get-timeline :public
|
||||
:local t
|
||||
:min-id minimum-id)))
|
||||
(let* ((toots (api-client:sort-id< (api-client:get-timeline :public
|
||||
:local t
|
||||
:min-id minimum-id)))
|
||||
(last-toot (lastcar toots)))
|
||||
(when last-toot
|
||||
(dump-minimum-id (tooter:id last-toot))
|
@ -743,6 +743,8 @@
|
||||
:+default-converation-timeline+
|
||||
:+message-index-start+
|
||||
:+tag-separator+
|
||||
:+make-close+
|
||||
:prepare-table
|
||||
:hidden-recipient-p
|
||||
:default-timelines
|
||||
:message-index->sequence-index
|
||||
@ -1415,6 +1417,7 @@
|
||||
:poll-vote
|
||||
:get-notifications
|
||||
:delete-notification
|
||||
:sort-id<
|
||||
:all-mentions
|
||||
:update-mentions-folder
|
||||
:expand-status-thread
|
||||
|
Loading…
Reference in New Issue
Block a user