Skip to content

Instantly share code, notes, and snippets.

@cstrachan88
Created January 11, 2019 14:23
Show Gist options
  • Save cstrachan88/66d104aa9c01a7cf633ac6322bd4e685 to your computer and use it in GitHub Desktop.
Save cstrachan88/66d104aa9c01a7cf633ac6322bd4e685 to your computer and use it in GitHub Desktop.
Yarn 1.13.0 global files for @vue/cli
#!/bin/sh
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
case `uname` in
*CYGWIN*) basedir=`cygpath -w "$basedir"`;;
esac
if [ -x "$basedir//bin/sh" ]; then
"$basedir//bin/sh" "$basedir/../Data/global/node_modules/.bin/vue" "$@"
ret=$?
else
/bin/sh "$basedir/../Data/global/node_modules/.bin/vue" "$@"
ret=$?
fi
exit $ret
@"%~dp0\..\Data\global\node_modules\.bin\vue.cmd" %*
#!/usr/bin/env pwsh
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
$exe=""
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
# Fix case when both the Windows and Linux builds of Node
# are installed in the same directory
$exe=".exe"
}
& "$basedir/../Data/global/node_modules/.bin/vue.cmd" $args
exit $LASTEXITCODE
#!/bin/sh
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
case `uname` in
*CYGWIN*) basedir=`cygpath -w "$basedir"`;;
esac
if [ -x "$basedir/pwsh" ]; then
"$basedir/pwsh" "$basedir/../Data/global/node_modules/.bin/vue.ps1" "$@"
ret=$?
else
pwsh "$basedir/../Data/global/node_modules/.bin/vue.ps1" "$@"
ret=$?
fi
exit $ret
@IF EXIST "%~dp0\pwsh.exe" (
"%~dp0\pwsh.exe" "%~dp0\..\Data\global\node_modules\.bin\vue.ps1" %*
) ELSE (
@SETLOCAL
@SET PATHEXT=%PATHEXT:;.JS;=;%
pwsh "%~dp0\..\Data\global\node_modules\.bin\vue.ps1" %*
)
#!/usr/bin/env pwsh
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
$exe=""
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
# Fix case when both the Windows and Linux builds of Node
# are installed in the same directory
$exe=".exe"
}
$ret=0
if (Test-Path "$basedir/pwsh$exe") {
& "$basedir/pwsh$exe" "$basedir/../Data/global/node_modules/.bin/vue.ps1" $args
$ret=$LASTEXITCODE
} else {
& "pwsh$exe" "$basedir/../Data/global/node_modules/.bin/vue.ps1" $args
$ret=$LASTEXITCODE
}
exit $ret
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment