aboutsummaryrefslogtreecommitdiff
path: root/scripts/.scripts
diff options
context:
space:
mode:
authoromagdy7 <omar.professional8777@gmail.com>2023-07-30 15:58:58 +0300
committeromagdy7 <omar.professional8777@gmail.com>2023-07-30 15:58:58 +0300
commitac1806ef623cc7007343ac5f3ee52ebe73f74fdb (patch)
treec154e3ecad3f271d6bd689fbc221e1ea3aa31079 /scripts/.scripts
parent090b6cc33137ab20a6d7206f67b8ca31f93cd9ee (diff)
downloaddotfiles-ac1806ef623cc7007343ac5f3ee52ebe73f74fdb.tar.xz
dotfiles-ac1806ef623cc7007343ac5f3ee52ebe73f74fdb.zip
Created a new script that creates a temp file and let's you choose an extention using dmenu and also added a dictionary to the dotfiles
Diffstat (limited to 'scripts/.scripts')
-rwxr-xr-xscripts/.scripts/create_tmp.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/.scripts/create_tmp.sh b/scripts/.scripts/create_tmp.sh
new file mode 100755
index 0000000..5855e2a
--- /dev/null
+++ b/scripts/.scripts/create_tmp.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# Choose an extenstion for the temp file
+choice=$(echo -e "cpp\nc\npy\nrs\njs\nts\ngo\ntxt\nmd\nhtml\ncss"| dmenu -p "Select extension: " -l 10)
+
+# choose random word from a dictionary
+random_word=$(cat /usr/share/dict/cracklib-small | shuf -n 1)
+
+# create temp file and open it in nvim
+kitty -e nvim /tmp/$random_word.$choice
+
+