delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-1.0 required=5.0 tests=AWL,BAYES_00,FORGED_HOTMAIL_RCVD2,FREEMAIL_FROM,T_RP_MATCHES_RCVD,T_TO_NO_BRKTS_FREEMAIL |
X-Spam-Check-By: | sourceware.org |
Message-ID: | <31148119.post@talk.nabble.com> |
Date: | Mon, 14 Mar 2011 13:18:03 -0700 (PDT) |
From: | PeterSmith <petervdkerk AT hotmail DOT com> |
To: | cygwin AT cygwin DOT com |
Subject: | Re: Autostart Cygwin on Windows boot and run a cygwin command |
In-Reply-To: | <4D7E7289.7010602@bopp.net> |
MIME-Version: | 1.0 |
References: | <31144428 DOT post AT talk DOT nabble DOT com> <4D7E5A1D DOT 5030702 AT bopp DOT net> <31147099 DOT post AT talk DOT nabble DOT com> <4D7E6112 DOT 1030405 AT bopp DOT net> <31147631 DOT post AT talk DOT nabble DOT com> <4D7E7289 DOT 7010602 AT bopp DOT net> |
X-IsSubscribed: | yes |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
Jeremy Bopp-3 wrote: > > On 3/14/2011 14:21, PeterSmith wrote: >> Ok, so for now lets focus on the contents of the .bat file. I'll have a >> look >> at the startup of the bat later :) > > Excellent idea, especially considering that it's not really a Cygwin > problem at that point. ;-) > >> I now have this: >> @echo off >> C: >> chdir C:\cygwin\bin >> bash -c "cd >> /cygdrive/e/solr/apache-solr-4.0-2010-10-12_08-05-48/example/;java >> -Dsolr.solr.home=\"./example-DIH/solr/\" -jar start.jar" >> >> >> But that still gives me the exact same error: >> C:\>start_cygwin.bat >> bash: line 0: cd: >> /cygdrive/e/solr/apache-solr-4.0-2010-10-12_08-05-48/example/: No such >> file >> or dir >> ectory >> Unable to access jarfile start.jar >> C:\cygwin\bin> > > I think the "Unable to access..." error message is actually coming from > java.exe. That's likely because the cd before the java call failed > first, so you're not in the directory you expect to be when java is > started. Make sure you don't have a typo in that path to which you're > trying to cd. > > You may also consider replacing the ; in the command with && so that the > java command is never run if the cd fails. > > -Jeremy > > -- > Problem reports: http://cygwin.com/problems.html > FAQ: http://cygwin.com/faq/ > Documentation: http://cygwin.com/docs.html > Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple > > > It indeed was Java and also because there was a typo in my directory :) Thanks! -- View this message in context: http://old.nabble.com/Autostart-Cygwin-on-Windows-boot-and-run-a-cygwin-command-tp31144428p31148119.html Sent from the Cygwin list mailing list archive at Nabble.com. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |