From 1a6eaa6b666c58e0f0ed8a9daede2253558a52ec Mon Sep 17 00:00:00 2001 From: tokiclover Date: Sun, 5 Oct 2014 09:38:13 +0200 Subject: [PATCH] modules/firefox-profile: minor fix (+popd) --- modules/firefox-profile/functions/fhp | 2 +- modules/firefox-profile/init.zsh | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/firefox-profile/functions/fhp b/modules/firefox-profile/functions/fhp index 401fbeff..779e5a1e 100644 --- a/modules/firefox-profile/functions/fhp +++ b/modules/firefox-profile/functions/fhp @@ -11,6 +11,7 @@ function die { local ret=$? print -P " %F{red}%1x: %F{yellow}%U%I%u:%f $argv" >&2 + popd -q return $ret } @@ -28,7 +29,6 @@ if [[ -f $profile/.unpacked ]] { mv -f $profile{,.old}$ext if (( $? )) { die "failed to override the old tarball" - popd -q return } } diff --git a/modules/firefox-profile/init.zsh b/modules/firefox-profile/init.zsh index 07f3a7bd..2140c684 100644 --- a/modules/firefox-profile/init.zsh +++ b/modules/firefox-profile/init.zsh @@ -61,6 +61,7 @@ function { pushd -q "$fhpdir:h" || return tar -Ocp $profile | $=compressor $profile$ext if (( $? )) { + popd -q die "failed to pack a new tarball" return }