Find solution

How to execute Unix shell script from Windows?

Check our answers to ‘How to execute Unix shell script from Windows?’ - we found 35 replies and comments relevant to this matter. The best answers are submitted by users of Stack Overflow, Quora and Ask.Metafilter.Com.

Best solution

  • unable to execute a .sh script with Jsch

    i'm trying to execute a script shell in a unix server from my java application (on my windows seven station) using the ssh api Jsch. the script shell i'm using "start_lm" is a C binary. this is the code i'm using (it's from the Jsch website exemples) try{ JSch jsch=new JSch(); Session session=jsch.getSession(user, host, 22); UserInfo ui=new MyUserInfo(); session.setUserInfo(ui); session.connect(); String command="user/psi/start_lm"; Channel channel=session.openChannel...

    Answer:

    There's the problem I believe ". ./start_lm.sh It should be below provided script present in current...

    Mark as irrelevant Undo

Other solutions

  • Is it possible to get stored procedure data using Unix shell script?

    I am writing a shell script to execute a stored procedure (no IN parameters) and i need the output of stored procedure as variables in the script itself for other logic. Is it possible to write those data into a file and read it from there? if yes, Please...

    Answer:

    If you meant database stored procedures and its variables, it.may output the name and value of its variables...

    Mark as irrelevant Undo
  • Why did Microsoft never develop the command prompt like the Unix shell?

    If you have been using Unix for some time now (mostly as a software developer) and use Windows for some tasks, it is quite likely you would not find the same kind of functionalities on Windows command prompt. Shell scripting gave so much power to Unix...

    Answer:

    There's plenty of analogous commands for PowerShell that match the functionality of Unix: UNIX For DOS...

    Mark as irrelevant Undo
  • Unix Scripting

    Unix scripting question- how do I automate an interactive command-line application? [MI] I'm using a proprietary FTP application to transmit a file each day, and pick up a receipt of the prior day's file. The application accepts various command line...

    Answer:

    expect is great for this sort of thing. It even has a learn mode that lets you do some tasks then creates...

    Mark as irrelevant Undo
  • Is there something better than Bash for shell scripting?

    Tomorrow I have to script a bunch of tasks using bash and, frankly, I am not looking forwards to it.  Any suggestions for something similar but better?  It has to be lighter-weight than Python, stable, and the ability to use it on Windows as well as...

    Answer:

    Back in the dark ages, this question was asked frequently, and the inevitable result was the creation...

    Mark as irrelevant Undo
  • Microsoft Backticks

    How do I get the ouput of a windows console program / script into a batch file variable? Unix user here, trying to translate a shell script into a batch file that will run in a Windows command shell environment. I need to get the output of a program...

    Answer:

    You can probably do this in an XP batch file. Read the help for the "for" statement, for ...

    Mark as irrelevant Undo
  • Folders appear on pendrive and reappear when deleted. How can I completely delete it?

    I have a problem, folders appear on pendrive and reappear when deleted. The folder is 'My Document' and 'Download' and also ('servieca'--a vbs script file...) I have deleted all and format and also reformat my pendrive, but the file and folders reappear...

    Answer:

    i do believe you've got some malware installed on your pendrive, or maybe it's on the computers you...

    Mark as irrelevant Undo
  • Parsing DLL in VB.Net

    I am trying to "Register an Application to a URL Protocol" (Refer to: http://msdn.microsoft.com/workshop/networking/pluggable/overview/appendix_a.asp?frame=true ) I ran the registry script (provided in the article): [HKEY_CLASSES_ROOT] [note...

    Answer:

    Hi. This is a pretty straightforward question. The following snippet of VB.NET code will compile and...

    Mark as irrelevant Undo
  • Why does JAVA require a JDBC-ODBC bridge to connect to a database?

    Why can it not use a ODBC connection ,like a windows or a unix program would?For example, I can write a shell script and connect to a db using the ODBC driver only. So why Java needs an additional JDBC-ODBC bridge for the connection?

    Answer:

    ODBC is a fairly old and low level API specified by Microsoft a long, long, long time ago. It defines...

    Mark as irrelevant Undo
  • UNIX shell script question?

    Hi guys, I want to create a shell script file (let's say 'answers'), which will call another script file (let's say 'questions'). The 'questions' script will ask three questions: what's your name?, what's your address?, who is your wife?. Then, 'answers...

    Answer:

    I'd use a temp file and have questions write the results there, and then answers can open it. You may...

    Mark as irrelevant Undo