From b3b51107239f29b31865f6a21bc8c4e59059ba0a Mon Sep 17 00:00:00 2001 From: laggardkernel Date: Fri, 11 Jan 2019 16:45:02 +0800 Subject: [PATCH] Fix: change replstr into variable in forgit::ignore::get --- forgit.plugin.sh | 2 +- forgit.plugin.zsh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/forgit.plugin.sh b/forgit.plugin.sh index 2b2003c..99854a9 100755 --- a/forgit.plugin.sh +++ b/forgit.plugin.sh @@ -160,7 +160,7 @@ __forgit_ignore_update() { __forgit_ignore_get() { mkdir -p $FORGIT_GI_CACHE for item in "$@"; do - cat "$FORGIT_GI_CACHE/$item" 2>/dev/null || (curl -sL https://www.gitignore.io/api/{} |tee "$FORGIT_GI_CACHE/$item") + cat "$FORGIT_GI_CACHE/$item" 2>/dev/null || (curl -sL "https://www.gitignore.io/api/$item" |tee "$FORGIT_GI_CACHE/$item") done } __forgit_ignore_clean() { diff --git a/forgit.plugin.zsh b/forgit.plugin.zsh index 95640b3..64d6e28 100644 --- a/forgit.plugin.zsh +++ b/forgit.plugin.zsh @@ -156,7 +156,7 @@ forgit::ignore::update() { forgit::ignore::get() { mkdir -p $FORGIT_GI_CACHE for item in "$@"; do - cat "$FORGIT_GI_CACHE/$item" 2>/dev/null || (curl -sL https://www.gitignore.io/api/{} |tee "$FORGIT_GI_CACHE/$item") + cat "$FORGIT_GI_CACHE/$item" 2>/dev/null || (curl -sL "https://www.gitignore.io/api/$item" |tee "$FORGIT_GI_CACHE/$item") done } forgit::ignore::clean() {