Vote count: 0 I'm trying to do simple batch script (cmd) that will check if required packages are installed, if not it will install them and then will call my command. I've managed to check if node is installed using: node -v >nul 2>nul if %errorlevel%==9009 ( echo Install node.js and restart this script goto :EOF ) now I'm trying to check if specific npm package exists. I'm able to display error when package is not installed using: npm list bootprint --depth=0 >nul 2>nul || echo bootprint not found! but every line after after that isn't evaluated. Below is my full code: @echo off setlocal EnableDelayedExpansion ::check if node.js is installed node -v >nul 2>nul if %errorlevel%==9009 ( echo...
ادامه مطلب