From 4ac843210dd4567fe91e4dde914bf58a444f3a25 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Thu, 9 Mar 2023 11:09:42 +0100 Subject: changed model to curie for poor reasons --- bin/common/ask | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bin/common') diff --git a/bin/common/ask b/bin/common/ask index 140d9f6..a06e3c7 100755 --- a/bin/common/ask +++ b/bin/common/ask @@ -12,7 +12,7 @@ test -z "${inp:=$@}" && prompt="$(echo "$inp" | tr "\n\t\"" " '")" API_KEY="$(pass tokens/openai-api)" -model="text-ada-001" +model="text-curie-001" tokens="1024" temperature=0 -- cgit v1.2.3 From 8d73085ec9575fb00b14956be8ae66081e98e714 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Thu, 9 Mar 2023 22:52:50 +0100 Subject: changed ytclipo alias to a script --- bin/common/ytclipo | 17 +++++++++++++++++ config/essentials/zsh/aliases.zsh | 1 - 2 files changed, 17 insertions(+), 1 deletion(-) create mode 100755 bin/common/ytclipo (limited to 'bin/common') diff --git a/bin/common/ytclipo b/bin/common/ytclipo new file mode 100755 index 0000000..ee5bf0f --- /dev/null +++ b/bin/common/ytclipo @@ -0,0 +1,17 @@ +#!/bin/sh + +# argument ($1) -> clipboard -> stdin +test -z "${inp:=${1:-"$(xclip -sel c -o)"}}" \ + && inp="$(cat /dev/stdin)" + +echo "inp: ${inp}" 1>&2 +# take last link from clipboard +# works when link is from yt-local +inp="$(echo -n "$inp" | awk -F 'https?://' '{print $NF}')" +echo "inp: ${inp}" 1>&2 + +yt-dlp "$inp" \ + -f "b" \ + -S "res:720" \ + -P "$HOME/vids" \ + -o "%(title)s.%(ext)s" diff --git a/config/essentials/zsh/aliases.zsh b/config/essentials/zsh/aliases.zsh index 493248d..411ae73 100644 --- a/config/essentials/zsh/aliases.zsh +++ b/config/essentials/zsh/aliases.zsh @@ -87,7 +87,6 @@ alias vidlen='ffprobe -show_entries format=duration -v quiet -of csv="p=0" -i' alias whatsmyip='curl "ifconfig.me"' alias icognito='unset HISTFILE' alias penv='python -m venv' -alias ytclipo='yt-dlp "$(xclip -sel c -o)" -f "b" -S "res:720" -P $HOME/vids -o "%(title)s.%(ext)s"' alias -g '...'='../..' alias -g '....'='../../..' -- cgit v1.2.3 From 5d7cb2848ddafd56d9b9267c495f57d405bb906c Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Fri, 10 Mar 2023 15:16:21 +0100 Subject: added notification to ytclipo --- bin/common/ytclipo | 2 ++ 1 file changed, 2 insertions(+) (limited to 'bin/common') diff --git a/bin/common/ytclipo b/bin/common/ytclipo index ee5bf0f..0ac412c 100755 --- a/bin/common/ytclipo +++ b/bin/common/ytclipo @@ -9,9 +9,11 @@ echo "inp: ${inp}" 1>&2 # works when link is from yt-local inp="$(echo -n "$inp" | awk -F 'https?://' '{print $NF}')" echo "inp: ${inp}" 1>&2 +notify-send "ytclipo" "ytclipo
downloading $inp" yt-dlp "$inp" \ -f "b" \ -S "res:720" \ -P "$HOME/vids" \ -o "%(title)s.%(ext)s" +notify-send "ytclipo" "ytclipo
finished downloading." -- cgit v1.2.3