Since I have found a way to do what I needed if I ...
# spicedb
s
Since I have found a way to do what I needed if I manage to add zed relationship bulk-delete into my script, a new question arose, is there a known way to force yes to bulk-delete? All ways I have tried don't seem to work
Copy code
bash
yes | zed relationship bulk-delete context/folder
Copy code
bash
echo "y" | zed relationship bulk-delete context/folder
Copy code
bash
#!/usr/bin/expect

set timeout -1  ;# Set timeout to -1 for an indefinite wait

spawn zed relationship bulk-delete context/folder

expect {
    "Will delete * relationships. Continue?" {
        send "y\r"
        exp_continue
    }
    eof {
        exit 0
    }
}
Copy code
bash
#!/bin/bash

zed relationship bulk-delete context/folder
sleep 2

xdotool type "y"
xdotool key Return
I am out of ideas, if you have any (even if it you aren't sure) would be appreciated. Thank you.
2 Views