From 3559b1c113ff7b4fec99e3799b59c8a8ef0bca0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan-Ole=20H=C3=BCbner?= Date: Sun, 13 Apr 2025 19:36:21 +0200 Subject: [PATCH] fix(pass): ignore errors from pass --- .zsh_functions/insta.zsh | 2 +- .zsh_functions/youtube.zsh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.zsh_functions/insta.zsh b/.zsh_functions/insta.zsh index fca9843..efb1e9f 100644 --- a/.zsh_functions/insta.zsh +++ b/.zsh_functions/insta.zsh @@ -41,7 +41,7 @@ insta () { if ! $is_local_nas; then if ! check_smb_mount; then echo "Mounting SMB share..." - /sbin/mount_smbfs "smb://janolehuebner:$(pass sudo-lana)@$insta_share_on_nas" "$insta_mount_point" + /sbin/mount_smbfs "smb://janolehuebner:$(pass sudo-lana 2>/dev/null)@$insta_share_on_nas" "$insta_mount_point" fi if ! check_smb_mount; then echo "Failed to mount SMB share. Exiting." diff --git a/.zsh_functions/youtube.zsh b/.zsh_functions/youtube.zsh index 78269bd..771e49a 100644 --- a/.zsh_functions/youtube.zsh +++ b/.zsh_functions/youtube.zsh @@ -29,7 +29,7 @@ ytr () { return 1 fi - local token="$(pass $TUBE_TOKEN_NAME_IN_STORE)" + local token="$(pass $TUBE_TOKEN_NAME_IN_STORE 2>/dev/null)" local json_data=$(jq -n --arg youtube_id "$youtube_id" '{ data: [ { @@ -58,7 +58,7 @@ yts() { fi # Set the token and URL - local token="$(pass $TUBE_TOKEN_NAME_IN_STORE)" + local token="$(pass $TUBE_TOKEN_NAME_IN_STORE 2>/dev/null)" # Initialize an empty array to store video data local video_data="[]"