Migration feature in progress

This commit is contained in:
localhost_frssoft 2022-04-13 15:52:25 +03:00
parent 74f7bf9968
commit e4be40cf71

View file

@ -9,6 +9,7 @@ default_content_type=$(jj -i config.json default_content_type)
format_time=$(jj -i config.json format_time)
boost_symbol=$(jj -i config.json boost_symbol)
#[AUTH SECTION]
mkdir -m 711 -p .app_sessions
touch .auth.json
chmod 600 .auth.json
@ -65,6 +66,39 @@ auth_api_get_token()
--data-urlencode "code=$pass" | jj access_token)
jj -p -i .auth.json -v "$token" "$(echo $instance | sed 's/\./\\\./g')" -o .auth.json
}
#[AUTH SECTION END]
#[MIGRATION SECTION]
backup_api_create()
{
curl -s --compressed -X POST -H "Authorization: Bearer $auth" "$instance_point/pleroma/backups"
}
backup_api_list()
{
curl -s --compressed -H "Authorization: Bearer $auth" "$instance_point/pleroma/backups"
}
mutes_api_import()
{
curl -s --compressed -X POST -H "Authorization: Bearer $auth" "$instance_point/pleroma/mutes_import"
}
blocks_api_import()
{
curl -s --compressed -X POST -H "Authorization: Bearer $auth" "$instance_point/pleroma/blocks_import"
}
follow_api_import()
{
curl -s --compressed -X POST -H "Authorization: Bearer $auth" "$instance_point/pleroma/follow_import"
}
#[MIGRATION SECTION END]
followings_api_get()
{
default_curl_opt -H "Authorization: Bearer $auth" "$instance_point/accounts/$1/following?limit=40"
}
thread_api_statuses()
{