diff --git a/dots/bin/dragin.sh b/dots/bin/dragin.sh new file mode 100755 index 0000000..da5e783 --- /dev/null +++ b/dots/bin/dragin.sh @@ -0,0 +1,19 @@ +#!/usr/bin/env bash + +# klevstul :: 24.06 + +this_file_name=`basename "$0"` +#if [ $# -lt 2 ]; then +# echo "error: paths to file and directory are missing." +# echo "usage: '$this_file_name [path_to_file] [path_to_dir]'" +# exit 1 +#fi + +cwd=$(pwd) + +input_file=$(dragon-drop --target --and-exit) +input_file=${input_file:7} # remove "file://" from file path + +if [[ -f "${input_file}" ]] ; then + cp ${input_file} ${cwd} +fi diff --git a/dots/lf/lfrc b/dots/lf/lfrc index a449bbe..5f0d789 100644 --- a/dots/lf/lfrc +++ b/dots/lf/lfrc @@ -119,14 +119,7 @@ cmd zip ''${{ cmd dragon %dragon-drop --all --and-exit "$fx" cmd dragon-stay %dragon-drop --all "$fx" cmd dragon-individual %dragon-drop "$fx" - -cmd dragin ${{ - echo $1 - echo $fx - dragon-drop --target -}} - -# dragon-drop --target --and-exit +cmd dragin %dragin.sh # change dir cmd cda :cd /home/poq/syncDir/antijantepodden