fix
This commit is contained in:
parent
086b149b69
commit
e1d22a10d4
@ -1,12 +1,21 @@
|
||||
#!/bin/zsh
|
||||
|
||||
name=mitra-mitra-1
|
||||
#repeat 30 docker exec -it mitra-mitra-1 zsh -c "/app/mitractl generate-invite-code" |grep invite >> .config/ai/txt/mitra_invite.txt
|
||||
|
||||
case $1 in
|
||||
generate-invite-code|invite|i|code)
|
||||
docker exec -it $name bash -c "/app/mitractl generate-invite-code"|grep invite
|
||||
#name=mitra-mitra-1
|
||||
#docker exec -it $name bash -c "/app/mitractl generate-invite-code"|grep invite
|
||||
|
||||
f=~/.config/ai/txt/mitra_invite.txt
|
||||
cat $f|awk "NR==1"
|
||||
|
||||
case $OSTYPE in
|
||||
darwin*)
|
||||
sed -i "" 1d $f
|
||||
;;
|
||||
linux*)
|
||||
sed -i 1d $f
|
||||
;;
|
||||
*)
|
||||
docker exec -it $name bash -c "/app/mitractl $1"|grep invite
|
||||
sed -i 1d $f
|
||||
;;
|
||||
esac
|
||||
|
@ -321,10 +321,12 @@ pub fn c_bot(c: &Context) {
|
||||
let d = String::from_utf8_lossy(&output.stdout);
|
||||
let d = "\n".to_owned() + &d.to_string();
|
||||
let text_limit = c_char(d);
|
||||
link = "https://m.syu.is".to_string();
|
||||
e = link.chars().count();
|
||||
if text_limit.len() > 3 {
|
||||
let str_rep = reply_link::post_request(
|
||||
text_limit.to_string(),
|
||||
"https://m.syu.is".to_string(),
|
||||
link.to_string(),
|
||||
s,
|
||||
e.try_into().unwrap(),
|
||||
cid.to_string(),
|
||||
|
Loading…
Reference in New Issue
Block a user