After gemini-propoesed fixes
This commit is contained in:
parent
2e31283b61
commit
83324dd0f7
11 changed files with 228 additions and 307 deletions
21
daisy.source
21
daisy.source
|
|
@ -24,7 +24,6 @@ function ld_dbg
|
|||
then
|
||||
$@
|
||||
fi
|
||||
echo
|
||||
}
|
||||
|
||||
# Variables for use in other utilities
|
||||
|
|
@ -38,10 +37,11 @@ fi
|
|||
# Check for dependencies
|
||||
function _daisy_dependency_check
|
||||
{
|
||||
BIN=$(command -v $1 2>/dev/null)
|
||||
res=$?
|
||||
|
||||
echo $(($res ^ 1))
|
||||
if command -v "$1" >/dev/null 2>&1; then
|
||||
echo 1
|
||||
else
|
||||
echo 0
|
||||
fi
|
||||
}
|
||||
|
||||
LD_HAS_fzf=$(_daisy_dependency_check fzf)
|
||||
|
|
@ -88,10 +88,9 @@ ld_dbg cat $LD_EDITORFILE
|
|||
# Source everything in the config folder
|
||||
function _daisy_source_configs
|
||||
{
|
||||
for f in `find "$LD_CONFIG_FOLDER" -name "*.src" -type f`;
|
||||
do
|
||||
source "$f"
|
||||
done
|
||||
while IFS= read -r -d '' f; do
|
||||
source "$f"
|
||||
done < <(find "$LD_CONFIG_FOLDER" -name "*.src" -type f -print0)
|
||||
}
|
||||
|
||||
# Installation into PATH
|
||||
|
|
@ -124,7 +123,7 @@ function daisy_wait_for_editor
|
|||
|
||||
while true;
|
||||
do
|
||||
alive=$(ps aux | grep $fname | grep $pname)
|
||||
alive=$(pgrep -f "$pname.*$fname")
|
||||
if [[ $alive == "" ]]
|
||||
then
|
||||
break
|
||||
|
|
@ -265,7 +264,7 @@ function ched
|
|||
for editor in "${editors[@]}";
|
||||
do
|
||||
editor_real=$(command -v "$editor")
|
||||
if command -v "$editor_rmeal" >/dev/null 2>&1;
|
||||
if command -v "$editor_real" >/dev/null 2>&1;
|
||||
then
|
||||
if [[ $(realpath "$EDITOR") == "$editor_real" ]];
|
||||
then
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue