fix
This commit is contained in:
parent
57013e14ee
commit
e3faeeb975
20
at.zsh
20
at.zsh
@ -11,10 +11,10 @@ host=(
|
|||||||
plc.directory
|
plc.directory
|
||||||
)
|
)
|
||||||
lexicon=(
|
lexicon=(
|
||||||
/xrpc/com.atproto.repo.describeRepo
|
com.atproto.repo.describeRepo
|
||||||
/xrpc/com.atproto.repo.getRecord
|
com.atproto.repo.getRecord
|
||||||
/xrpc/com.atproto.repo.listRecords
|
com.atproto.repo.listRecords
|
||||||
/xrpc/com.atproto.identity.resolveHandle
|
com.atproto.identity.resolveHandle
|
||||||
)
|
)
|
||||||
|
|
||||||
function at-env(){
|
function at-env(){
|
||||||
@ -62,6 +62,15 @@ function at-collection-search(){
|
|||||||
curl -sL "$url?repo=$did&collection=$collection&reverse=$reverse"|jq .
|
curl -sL "$url?repo=$did&collection=$collection&reverse=$reverse"|jq .
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function at-docs(){
|
||||||
|
for i in $lexicon; do
|
||||||
|
req=`echo $i|tr '.' '-'|sed 's/[A-Z]/-&/g'|tr '[A-Z]' '[a-z]'`
|
||||||
|
url=https://docs.bsky.app/docs/api/$req
|
||||||
|
echo $url
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
at-env
|
at-env
|
||||||
case $1 in
|
case $1 in
|
||||||
uri|u)
|
uri|u)
|
||||||
@ -73,6 +82,9 @@ case $1 in
|
|||||||
collection|c)
|
collection|c)
|
||||||
at-collection-search $2 $3
|
at-collection-search $2 $3
|
||||||
;;
|
;;
|
||||||
|
at-docs|docs)
|
||||||
|
at-docs
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
echo "${help[@]}"
|
echo "${help[@]}"
|
||||||
echo "${host[@]}"
|
echo "${host[@]}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user