Compare commits

...

3 Commits

Author SHA1 Message Date
Steve Ayerhart b42addcde3
post by default 2022-01-24 08:10:42 -05:00
Steve Ayerhart 8ed2daf5ad
pooled-ed 2022-01-24 08:10:31 -05:00
Steve Ayerhart 96c16902f1
math.ranges -> ranges 2022-01-24 08:10:12 -05:00
3 changed files with 10 additions and 10 deletions

View File

@ -1,6 +1,6 @@
! Copyright (C) 2020 .
! See http://factorcode.org/license.txt for BSD license.
USING: kernel math math.ranges math.order math.parser math.functions arrays sequences sequences.extras threads calendar io timers accessors random formatting combinators combinators.random http.server.responses regexp unicode peg peg.parsers assocs db.types db.tuples ;
USING: kernel math math.order math.parser math.functions ranges arrays sequences sequences.extras threads calendar io timers accessors random formatting combinators combinators.random http.server.responses regexp unicode peg peg.parsers assocs db.types db.tuples ;
USING: bonerbonerboner.services ;
FROM: bonerbonerboner.services.slack => slack-lookup-user say-slack ;
@ -76,7 +76,7 @@ mississippis "mississippis"
"GO!" announce ;
: announce-standard-mississippis ( terminal -- )
[1,b] [ standard-mississippi-duration sleep announce-sip ] each ;
[1..b] [ standard-mississippi-duration sleep announce-sip ] each ;
:: announce-nonstandard-mississippi ( terminal sip -- )
{
@ -89,7 +89,7 @@ mississippis "mississippis"
: announce-nonstandard-mississippis ( terminal -- )
[
[ dup <array> ] [ 1 - [1,b] ] bi
[ dup <array> ] [ 1 - [1..b] ] bi
[ nonstandard-mississippi-wait announce-nonstandard-mississippi ] 2each
]
[ announce-sip ] bi ;

View File

@ -1,7 +1,7 @@
! Copyright (C) 2020 .
! See http://factorcode.org/license.txt for BSD license.
USING: kernel fry db db.sqlite environment math.parser io.pathnames ;
USING: kernel fry db db.pools db.sqlite environment math.parser io.pathnames ;
IN: bonerbonerboner.services
@ -10,11 +10,11 @@ CONSTANT: bbb-default-port 8069
: bbb-data-directory ( -- path )
home ".bonerbonerboner" append-path ;
: <bbb-sqlite-db> ( -- db )
bbb-data-directory "bbb.db" append-path <sqlite-db> ;
: <bbb-sqlite-db> ( -- db-pool )
bbb-data-directory "bbb.db" append-path <sqlite-db> <db-pool> ;
: with-bbb-db ( quot -- )
'[ <bbb-sqlite-db> _ with-db ] call ; inline
'[ <bbb-sqlite-db> _ with-pooled-db ] call ; inline
: bbb-api-port ( -- port )
"BBB_API_PORT" os-env [ string>number ] [ bbb-default-port ] if* ;

View File

@ -58,6 +58,6 @@ TUPLE: slack < dispatcher ;
http-request 2drop ;
: say-slack ( str -- )
. flush ;
! "text" associate
! slack-post-message ;
! . flush ;
"text" associate
slack-post-message ;