From 60b4ebfbf3be78dba9dc7c65ab2bdaa0b218c0c2 Mon Sep 17 00:00:00 2001 From: Andrew Opalach Date: Mon, 21 Oct 2024 19:22:50 -0400 Subject: Everything before initial synced list Signed-off-by: Andrew Opalach --- scripts/cmv.sh | 18 ++++++++++++++++++ scripts/cmv_add.sh | 4 ++-- scripts/line_count.sh | 7 ++++--- scripts/run.sh | 5 ++++- scripts/run_debug.sh | 2 +- scripts/run_server.sh | 5 ++++- scripts/run_valgrind.sh | 2 ++ 7 files changed, 35 insertions(+), 8 deletions(-) create mode 100755 scripts/cmv.sh create mode 100755 scripts/run_valgrind.sh (limited to 'scripts') diff --git a/scripts/cmv.sh b/scripts/cmv.sh new file mode 100755 index 0000000..0bf2de5 --- /dev/null +++ b/scripts/cmv.sh @@ -0,0 +1,18 @@ +#! /usr/bin/env bash +ORIGIN="$PWD" +CMD=() +for dir in "$@" +do + if [[ $dir == http\://* || $dir == https\://* || $dir == cdda\://* ]]; then + EXP=$dir + else + EXP=$(realpath -s "`printf '%b' \"$dir\"`") + if [[ ! -f $EXP ]]; then + EXP=";"$dir + fi + fi + CMD+=("$EXP") +done +cd $HOME/c/camu/build/ +../scripts/run.sh "${CMD[@]}" +cd "$ORIGIN" diff --git a/scripts/cmv_add.sh b/scripts/cmv_add.sh index 700b21b..26f5547 100755 --- a/scripts/cmv_add.sh +++ b/scripts/cmv_add.sh @@ -2,7 +2,7 @@ CMD="" for dir in "$@" do - if [[ $dir == http\://* || $dir == https\://* ]]; then + if [[ $dir == http\://* || $dir == https\://* || $dir == cdda\://* ]]; then EXP=$dir else EXP=$(realpath -s "`printf '%b' \"$dir\"`") @@ -12,4 +12,4 @@ do fi CMD="$CMD""$EXP\n" done -echo -e "$CMD""X" | socat - UNIX-CONNECT:/tmp/camu_sock +echo -e "$CMD""X" | socat - UNIX-CONNECT:/tmp/cmv_sock diff --git a/scripts/line_count.sh b/scripts/line_count.sh index 19844b9..31e72ab 100755 --- a/scripts/line_count.sh +++ b/scripts/line_count.sh @@ -1,8 +1,9 @@ #! /usr/bin/env sh find ./src -type f \ - -not -path "./src/portal/vendor/*" \ - -not -path "./src/portal/patches/*" \ -not -path "./src/portal/cpy/portal.c" \ -not -path "./src/portal/cpy/portal.h" \ + -not -path "./src/portal/patches/*" \ + -not -path "./src/portal/tests/*" \ + -not -path "./src/portal/vendor/*" \ -not -path "*__pycache__*" \ - | xargs wc -l + -exec wc -l {} + diff --git a/scripts/run.sh b/scripts/run.sh index f2bbaa0..40f34d7 100755 --- a/scripts/run.sh +++ b/scripts/run.sh @@ -1,3 +1,6 @@ #! /usr/bin/env sh +export CURL_CA_BUNDLE=/etc/ssl/certs/ca-bundle.crt +export PYTHONDONTWRITEBYTECODE=1 +export PYTHONPATH=$HOME/c/camu/src/portal/vendor/vendor export mesa_glthread=true -./src/fruits/sink/sink "$@" +nixGLIntel ./src/fruits/cmv/cmv "$@" diff --git a/scripts/run_debug.sh b/scripts/run_debug.sh index 8b8b329..bd9a667 100755 --- a/scripts/run_debug.sh +++ b/scripts/run_debug.sh @@ -1,2 +1,2 @@ #! /usr/bin/env sh -gdb -ex run --args ./src/fruits/sink/sink "$@" +gdb -ex run --args ./src/fruits/cmv/cmv "$@" diff --git a/scripts/run_server.sh b/scripts/run_server.sh index 1c2cbbf..4e65e48 100755 --- a/scripts/run_server.sh +++ b/scripts/run_server.sh @@ -1,4 +1,7 @@ #! /usr/bin/env sh +export CURL_CA_BUNDLE=/etc/ssl/certs/ca-bundle.crt export PYTHONDONTWRITEBYTECODE=1 export PYTHONPATH=$HOME/c/camu/src/portal/vendor/vendor -rm -f /tmp/camu_sock && gdb -ex run --args ./src/server/server $@ +./src/fruits/cmsrv/cmsrv $@ +#gdb -ex run --args ./src/fruits/cmsrv/cmsrv $@ +#valgrind ./src/fruits/cmsrv/cmsrv $@ diff --git a/scripts/run_valgrind.sh b/scripts/run_valgrind.sh new file mode 100755 index 0000000..943d25b --- /dev/null +++ b/scripts/run_valgrind.sh @@ -0,0 +1,2 @@ +#! /usr/bin/env sh +valgrind --leak-check=full ./src/fruits/cmv/cmv "$@" -- cgit v1.2.3-101-g0448