This commit is contained in:
Øyvind Jensen 2025-04-27 21:57:27 +02:00
commit 90f92d4c66
20 changed files with 425 additions and 0 deletions

20
bin/pyrep Executable file
View file

@ -0,0 +1,20 @@
#!/usr/bin/env python3
#
# Requirements: nrepl-python-client
#
import sys
import nrepl
code = sys.stdin.read().strip()
print(code)
c = nrepl.connect("nrepl://localhost:1667")
c.write({"op": "eval", "code": code})
response = c.read()
try:
print(";; " + response['value'])
except KeyError:
try:
print(";; ERROR: " + response['err'])
except KeyError:
pass