From 308432ccbbe64d62a754495238313d84f35f7eb6 Mon Sep 17 00:00:00 2001 From: Marley Rae Date: Mon, 29 Jan 2024 17:26:52 -0800 Subject: [PATCH] =?UTF-8?q?=E2=99=BB=EF=B8=8F=20=20Node=5Futils=20->=20fis?= =?UTF-8?q?h?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- node/node_utils.fish | 11 +++++++++++ node/node_utils.sh | 15 --------------- 2 files changed, 11 insertions(+), 15 deletions(-) create mode 100644 node/node_utils.fish delete mode 100644 node/node_utils.sh diff --git a/node/node_utils.fish b/node/node_utils.fish new file mode 100644 index 0000000..320b8c5 --- /dev/null +++ b/node/node_utils.fish @@ -0,0 +1,11 @@ +#!/usr/bin/env fish + +source "$DOT/script/utils.fish" + +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +function npm_install -a $msg $pkg + execute \ + "source $DOT/node/path.config.fish && npm install --global --silent $pkg" \ + "$msg" +end diff --git a/node/node_utils.sh b/node/node_utils.sh deleted file mode 100644 index 3806ff3..0000000 --- a/node/node_utils.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash -# vim:set ft=bash: - -cd "$(dirname "${BASH_SOURCE[0]}")" \ - && source "../script/utils.sh" - -# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -npm_install() -{ - local -r MSG="$1" - local -r PKG="$2" - - execute ". $DOT/node/path.zsh && npm install --global --silent $PKG" "$MSG" -}