sh

sed and rev shell command into Python script

sed and rev shell command into Python script Question: There is a shell command, I am trying to convert the logic into python. But I don’t know what to do, I need some help with that. shell command is this : cd ../../../tests/src/main/test ls find . -name ‘*.vrlp’ | while read FILENAME do TEST_CASE=`echo $FILENAME …

Total answers: 1

Shell find logic into Python script

Shell find logic into Python script Question: cd db/test/vs ls find . -name ‘*.vrlp’ | while read FILENAME do TEST_CASE=`echo $FILENAME | sed s/"./"//g | sed s/".vrlp"//g | rev | cut -f1 -d"/" | rev` CLASS=`echo $FILENAME | sed s/"./"//g | sed s/"/$TEST_CASE"//g | sed s/".vrlp"//g` done There are a lot of class files (FILENAME) …

Total answers: 1

sed shell command into Python script

sed shell command into Python script Question: There is a shell command, I am trying to convert the logic into python. But I don’t know what to do, I need some help with that. shell command is this : cd ../../../tests/src/main/java ls grep -R "@Test" -A 1 | grep void | while read LINE do …

Total answers: 1

Why a dockerized script have a different behaviour when I docker run or I docker execute it?

Why a dockerized script have a different behaviour when I docker run or I docker execute it? Question: I’m using a python script for send websocket notification, as suggested here. The script is _wsdump.py and I have a script script.sh that is: #!/bin/sh set -o allexport . /root/.env set env python3 /utils/_wsdump.py "wss://mywebsocketserver:3000/message" -t "message" …

Total answers: 2

how to fix "Operation not permitted" when i use launchctl in macos catalina

how to fix "Operation not permitted" when i use launchctl in macos catalina Question: I’m setting up a launchctl server to run a python file regularly. So I write a.plist file , auto.sh file and it works well. However, after I installed Macos Catalina, it failed. I write “ls -l” in auto.sh to check file …

Total answers: 6