about summary refs log tree commit diff stats
path: root/home-manager/packages/scripts/small_functions/deprecated
diff options
context:
space:
mode:
authorene <ene@sils.li>2023-02-25 07:54:37 +0100
committerene <ene@sils.li>2023-02-25 07:54:37 +0100
commit06696ca201682f63ea50da3ab41d992ed6b61816 (patch)
tree93152237a2e968cd433d1ca21671dcba52e772b8 /home-manager/packages/scripts/small_functions/deprecated
parentFix(hosts): Update UUIDs for mammun hosts (diff)
downloadnixos-config-06696ca201682f63ea50da3ab41d992ed6b61816.zip
Feat(packages): Add my scripts
Diffstat (limited to '')
-rwxr-xr-xhome-manager/packages/scripts/small_functions/deprecated/locate_rewrite/locate2
-rwxr-xr-xhome-manager/packages/scripts/small_functions/deprecated/locate_rewrite/update_locate_database8
-rwxr-xr-xhome-manager/packages/scripts/small_functions/deprecated/order12
-rwxr-xr-xhome-manager/packages/scripts/small_functions/deprecated/ply-pre33
4 files changed, 55 insertions, 0 deletions
diff --git a/home-manager/packages/scripts/small_functions/deprecated/locate_rewrite/locate b/home-manager/packages/scripts/small_functions/deprecated/locate_rewrite/locate
new file mode 100755
index 00000000..3dbddae9
--- /dev/null
+++ b/home-manager/packages/scripts/small_functions/deprecated/locate_rewrite/locate
@@ -0,0 +1,2 @@
+#! /bin/bash
+awk --assign=se=$1 ' $0 ~ se {print $0} ' "${LOCATE_DATABASE}"
diff --git a/home-manager/packages/scripts/small_functions/deprecated/locate_rewrite/update_locate_database b/home-manager/packages/scripts/small_functions/deprecated/locate_rewrite/update_locate_database
new file mode 100755
index 00000000..88330ff6
--- /dev/null
+++ b/home-manager/packages/scripts/small_functions/deprecated/locate_rewrite/update_locate_database
@@ -0,0 +1,8 @@
+#! /bin/bash
+LOCATE_DATABASE="/home/dt/.cache/locate.db"
+if [ ! -e ${LOCATE_DATABASE} ]; then
+    touch ${LOCATE_DATABASE}
+fi
+echo $(date) > ${LOCATE_DATABASE}
+sudo find / >> ${LOCATE_DATABASE}
+
diff --git a/home-manager/packages/scripts/small_functions/deprecated/order b/home-manager/packages/scripts/small_functions/deprecated/order
new file mode 100755
index 00000000..1471fcbd
--- /dev/null
+++ b/home-manager/packages/scripts/small_functions/deprecated/order
@@ -0,0 +1,12 @@
+#!/bin/sh
+# shellcheck disable=SC2086
+# shellcheck source=/dev/null
+. ~/.local/lib/shell/lib
+
+file=$HOME/hi3
+cat $file | clean | awk  '{
+    print (""$2" => {println!(\""$1"\")}")
+}'
+
+
+if [ -d /tmp/LIB_FILE_TEMP_DIR/ ];then rm -r /tmp/LIB_FILE_TEMP_DIR/; fi
diff --git a/home-manager/packages/scripts/small_functions/deprecated/ply-pre b/home-manager/packages/scripts/small_functions/deprecated/ply-pre
new file mode 100755
index 00000000..8e40486c
--- /dev/null
+++ b/home-manager/packages/scripts/small_functions/deprecated/ply-pre
@@ -0,0 +1,33 @@
+#!/bin/sh
+
+# shellcheck source=/dev/null
+. ~/.local/lib/shell/lib
+
+
+## Preview Plymouth Splash ##
+##      by _khAttAm_       ##
+##    www.khattam.info     ##
+##    License: GPL v3      ##
+
+chk_root () {
+
+  if [ ! "$( id -u )" -eq 0 ]; then
+    echo Must be run as root
+    exit 1
+  fi
+
+}
+
+chk_root
+
+DURATION=$1
+
+if [ $# -ne 1 ]; then
+	DURATION=5
+fi
+
+plymouthd; plymouth --show-splash ; 
+for i in $(seq 1 $DURATION); do 
+    plymouth --update=test"$i" ; sleep 1; 
+done; 
+plymouth quit