سؤال

I'm trying to run the following .bat file using windows CMD:

lein run
cd..

The first line works perfectly fine and the clojure program does its job:

(spit some-file some-stuff)

The second line however never gets executed. Why is that?

هل كانت مفيدة؟

المحلول

My apologies in advance if I have misunderstood your question. From what I gather it sounds like changing folders within a script sets the new current folder within the script though it does not necessarily set the current folder from the perspective of the terminal that invoked the script.

it could make this more clear if you put a print statement after the cd .. to show you the directory from the perspective of the script.

نصائح أخرى

try this:

start /b "" lein run
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top