How can I run a batch file on macOS?

I’ve been attempting to install a mod for Elden Ring on Mac, and it uses a batch file to install and launch. I can’t seem to get it to run with Wine, receiving these errors:

0074:err:ntoskrnl:ZwLoadDriver failed to create driver L"RegistryMachineSystemCurrentControlSetServiceswineusb": c0000142
003c:fixme:service:scmdatabase_autostart_services Auto-start service L"wineusb" failed to start: 1114
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
00a8:fixme:keyboard:NtUserActivateKeyboardLayout Changing user locale is not supported
00bc:fixme:keyboard:NtUserActivateKeyboardLayout Changing user locale is not supported
Can't recognise 'Play Mod.bat' as an internal or external command, or batch script.

I was wondering if someone knew how to fix this, or the other thing I heard might be possible would be converting the file into a shell script and running that instead? I’m not very versed in this subject, and was wondering if someone could help me with that. Here are the contents of the batch file

@ECHO OFF && TITLE Launch DEN Maps Mod
SET ThisScriptsDirectory=%~dp0
SET PowerShellScriptPath=%ThisScriptsDirectory%ModFilesDenMaps1.7.0-beta2PSModInstallerPlayMod.ps1

@REM if PSModInstaller folder exists, and DenMaps not
IF EXIST "%ThisScriptsDirectory%PSModInstaller" (
    IF NOT EXIST "%ThisScriptsDirectory%DenMaps" (
        SET PowerShellScriptPath="%ThisScriptsDirectory%PSModInstallerPlayMod.ps1"
    )
)
PowerShell -NoProfile -ExecutionPolicy Bypass -Command "& '%PowerShellScriptPath%'";

I tried to run it using Wine cmd /c "Play Mod.bat" expected it to work, didn’t work and gave a bunch of errors instead.

Update: I attempted to run it by starting a new terminal directly from the folder it is in, and it gave me this set of errors

Matthews-Air:1.7.0-beta2 me$ wine cmd /c "Play Mod.bat"
0074:err:ntoskrnl:ZwLoadDriver failed to create driver L"\Registry\Machine\System\CurrentControlSet\Services\wineusb": c0000142
003c:fixme:service:scmdatabase_autostart_services Auto-start service L"wineusb" failed to start: 1114
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
009c:fixme:hid:handle_IRP_MN_QUERY_ID Unhandled type 00000005
00a8:fixme:keyboard:NtUserActivateKeyboardLayout Changing user locale is not supported
00bc:fixme:keyboard:NtUserActivateKeyboardLayout Changing user locale is not supported
0130:fixme:powershell:wmain stub: L"PowerShell" L"-NoProfile" L"-ExecutionPolicy" L"Bypass" L"-Command" L"& 'Z:\Users\me\Desktop\1.7.0-beta2\\ModFiles\DenMaps\1.7.0-beta2\PSModInstaller\PlayMod.ps1';"

8

Don’t use the batch file at all. It isn’t doing much.

I can’t guarantee the next (powershell) step will work, but you don’t need the batch file.

This command: PowerShell -NoProfile -ExecutionPolicy Bypass -Command "& '%PowerShellScriptPath%'";

Find the DOS LOOKING path to PlayMod.ps1 (from Wine’s point of view) and launch powershell directly using the modified above command.

It will be under path the batch file is in.

It will probably look something like:
PowerShell -NoProfile -ExecutionPolicy Bypass -Command "C:MyCoolModDLNewEldenRingModModFilesDenMaps1.7.0-beta2PSModInstallerPlayMod.ps1";

OR
PowerShell -NoProfile -ExecutionPolicy Bypass -Command "C:MyCoolModDLNewEldenRingModPSModInstallerPlayMod.ps1;

Better still.. look for a mac solution as @music2myear hinted at..

3

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật