print last message abra cmd
This commit is contained in:
parent
150f1665ae
commit
f02162d8ae
1 changed files with 11 additions and 0 deletions
11
abra.sh
11
abra.sh
|
@ -1 +1,12 @@
|
||||||
export CONFIG_VERSION=v1
|
export CONFIG_VERSION=v1
|
||||||
|
|
||||||
|
message() {
|
||||||
|
python3 -c """
|
||||||
|
import json
|
||||||
|
import os
|
||||||
|
lastfile = sorted(os.listdir('/root/.config/chatgpt-cli/session-history/'))[-1]
|
||||||
|
message = json.load(open(f'/root/.config/chatgpt-cli/session-history/{lastfile}'))
|
||||||
|
print(message['messages'][-1]['content'])
|
||||||
|
"""
|
||||||
|
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue