Save grade sync command

This commit is contained in:
nemunaire 2022-07-09 21:07:28 +02:00
parent 1d16f8056c
commit bab7db1746

View File

@ -2,6 +2,8 @@
# Usage : ./get_grades.py | jq -r 'to_entries | map([.key, .value.TP1, .value.TP2, .value.TP3]) | .[] | @csv'
# Sync to atsebay.t : ./get_grades.py | jq -r '[to_entries | .[] | {login: .key, score: .value.TP1}]' | curl -X PUT -d @- 'https://srs.nemunai.re/api/works/$ID_TP1/grades' -H 'Cookie: auth=foobar'
import base64
import hashlib
import hmac