From dff016528cdadcf15f8a246c5bd6730a4d549f07 Mon Sep 17 00:00:00 2001 From: Chris Antos Date: Wed, 17 May 2023 10:48:05 -0700 Subject: [PATCH] z.lua was missing some lines for z.cmd. The auto-init for z.cmd was missing a couple of lines. The HomeDir line, in particular, is important because it enables Lua to find the z.lua script. --- z.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/z.lua b/z.lua index 307644b..42b2abe 100755 --- a/z.lua +++ b/z.lua @@ -2703,6 +2703,8 @@ function z_windows_init(opts) else print('@echo off') print('setlocal EnableDelayedExpansion') + print('set "HomeDir=%~dp0"') -- So that Lua can find the z.lua file. + print('set "PathSave=%PATH%"') print('set "LuaExe=' .. os.interpreter() .. '"') print('set "LuaScript=' .. os.scriptname() .. '"') print(script_init_cmd)