automated terminal push

This commit is contained in:
Your Name
2025-02-07 16:12:39 -05:00
parent a8c03cdfb3
commit 3b547f2192
20 changed files with 655 additions and 3 deletions

View File

@@ -0,0 +1,62 @@
execute_robot_process_killer_capability () {
countLocalExecutions=1
while [ "$countLocalExecutions" -ne "$targetCountLocalExecutions" ];do
echo
echo "calling process_killer_capability_group [`date`]"
echo
execute_robot_process_killer_capability_group
countLocalExecutions=$((countLocalExecutions + 1))
sleep 1
done
echo
echo "i have been running for over a minute. exiting gracefully."
echo
echo "another robot should be following behind me..."
echo
}
execute_robot_process_killer_capability_group () {
for processName in $processNameGroup; do
echo "execute kill processes matching: "$processName
execute_robot_process_killer_capability_single $processName
done
}
execute_robot_process_killer_capability_single () {
processToKill=$1
if pgrep $processToKill > /dev/null;then
echo
echo " ** there are processes running that match: "$processToKill
echo
## ps aux | grep $processToKill
killall $processToKill
## ps aux | grep $processToKill
echo
echo " ** killed all of the "$processToKill" processes"
echo
fi
}

View File

@@ -0,0 +1,13 @@
## Here are the names of all the processes that we want killed.
## to add new ones,just following the same pattern.
set -- "Tor" "tor" "tor-browser" "Tor-Browser" "Tor Browser" "tor browser" "TorBrowser" "torbrowser" "firefox" "FindMy" ## you can add stuff here. put the process name in double quotes
processNameGroup=$@; ## don't touch this.
##
targetCountLocalExecutions=64; ## don't touch this.
##

View File

@@ -0,0 +1,18 @@
#!/bin/sh
##
## This script lists the running processes related to the robot
## This script is for local monitoring and verification.
##
## Questions or issues? Email me here:
##
## the.software.shinobi@gmail.com
##
##set -x
##set -e
##
watch -n 1 'ps aux | grep robot'

View File

@@ -0,0 +1,62 @@
#!/bin/sh
##
## This script is a digital hunter killer drone
## to terminate target application processes
## on the local system
##
## Questions or issues? Email me here:
##
## the.software.shinobi@gmail.com
##
#set -e;
#set -x;
##
## reset;
## clear;
## Navigate to the robot-killer-home-directory
pwd
cd /var/root/robot-process-killer/
pwd
ls -lha
## Load the robot configuration from external file
echo
echo "BEGIN: load robot process killer configuration from file"
echo
. ./load-robot-process-killer-configuration.sh
echo
echo "END: load robot process killer configuration from file"
echo
## Load the robot functions and "do work" functionality from external file
echo
echo "BEGIN: load robot process killer capability from file"
echo
. ./load-robot-process-killer-capability.sh
echo
echo "END: load robot process killer capability from file"
echo
## Exeute the robot process killer functionality
echo
echo "starting the robot process killer"
echo
execute_robot_process_killer_capability