mirror of
https://github.com/EdenQwQ/nixos.git
synced 2026-02-03 19:53:25 +08:00
init
This commit is contained in:
commit
96895ec3aa
100 changed files with 6349 additions and 0 deletions
18
home/programs/desktop/scripts/tofi/custom-command
Executable file
18
home/programs/desktop/scripts/tofi/custom-command
Executable file
|
|
@ -0,0 +1,18 @@
|
|||
#!/bin/sh
|
||||
|
||||
tmpfile=~/scripts/tofi/stored_commands
|
||||
stored=$(cat $tmpfile)
|
||||
|
||||
command=$(echo "$stored" | tofi --require-match=false)
|
||||
|
||||
if [ -z "$command" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
exec $command &
|
||||
|
||||
if grep -q "$command" "$tmpfile"; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "$command" >> $tmpfile
|
||||
Loading…
Add table
Add a link
Reference in a new issue