diff --git a/node_modules/.bin/mime b/node_modules/.bin/mime index 0dbddf07..91e5e16a 100644 --- a/node_modules/.bin/mime +++ b/node_modules/.bin/mime @@ -2,7 +2,7 @@ basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')") case `uname` in - *CYGWIN*) basedir=`cygpath -w "$basedir"`;; + *CYGWIN*|*MINGW*|*MSYS*) basedir=`cygpath -w "$basedir"`;; esac if [ -x "$basedir/node" ]; then diff --git a/node_modules/.bin/mime.cmd b/node_modules/.bin/mime.cmd index 81695620..746a2798 100644 --- a/node_modules/.bin/mime.cmd +++ b/node_modules/.bin/mime.cmd @@ -1,7 +1,17 @@ -@IF EXIST "%~dp0\node.exe" ( - "%~dp0\node.exe" "%~dp0\..\mime\cli.js" %* +@ECHO off +SETLOCAL +CALL :find_dp0 + +IF EXIST "%dp0%\node.exe" ( + SET "_prog=%dp0%\node.exe" ) ELSE ( - @SETLOCAL - @SET PATHEXT=%PATHEXT:;.JS;=;% - node "%~dp0\..\mime\cli.js" %* -) \ No newline at end of file + SET "_prog=node" + SET PATHEXT=%PATHEXT:;.JS;=;% +) + +"%_prog%" "%dp0%\..\mime\cli.js" %* +ENDLOCAL +EXIT /b %errorlevel% +:find_dp0 +SET dp0=%~dp0 +EXIT /b diff --git a/node_modules/.bin/mime.ps1 b/node_modules/.bin/mime.ps1 new file mode 100644 index 00000000..a6f6f470 --- /dev/null +++ b/node_modules/.bin/mime.ps1 @@ -0,0 +1,18 @@ +#!/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/node$exe") { + & "$basedir/node$exe" "$basedir/../mime/cli.js" $args + $ret=$LASTEXITCODE +} else { + & "node$exe" "$basedir/../mime/cli.js" $args + $ret=$LASTEXITCODE +} +exit $ret diff --git a/public/login.html b/public/login.html index 5bc9807f..fdfd6517 100644 --- a/public/login.html +++ b/public/login.html @@ -64,9 +64,9 @@