I just read the first lines
seems you need run the script by bash, then run the script by absolute path of install.sh
such as:
Third, you can change your script to
I tried using
in the script as you suggested.. and still get the same errors...
I also tried running with the entire path:
but no luck with that either...
---------- Post updated at 01:16 PM ---------- Previous update was at 01:15 PM ----------
Quote:
Originally Posted by scottn
The shebang is also wrong.
should be
I tried using the correct shebang as you suggested:
but got no success with that.
---------- Post updated at 01:20 PM ---------- Previous update was at 01:16 PM ----------
Even if i pretend to make some changes in the file.... like for example opening install.sh, then putting a space somewhere in the file, then deleting that space, and saving that file,.... then it works when I type the command:
It is only when I am trying to run it directly after unzipping it from the jar file, that I am not able to run it successfully.
So, is it corrupting it while unzipping it, or maybe not recognizing the file is in the directory, until I pretend to move or change it?... not sure.
Dear Experts,
I am an ERP consultant and would like to learn shell script. We are working on Linux SUSE 11.4 and I am very new to shell scripting. We can manually encrypt an excel file using "executable jar" through command prompt by placing the jar file & the file to be encrypted on a physical... (1 Reply)
Hi,
I am trying to write a shell script that will go to another folder and run the script in that folder. The folder structure is kind of like this:
/MainFolder/
|-> MainShellScript.sh
|
|-> Folder1/
|-----|-> script1.sh
|-----|-> FileToRun1.jar
|
|-> Folder2/
|-----|-> script2.sh... (3 Replies)
What would be the best way to store the name of an extracted file from a tar to a text file?
I want to extract one file from a tar and store the name of the extracted file to a temp file.
tar -xvf tar_file.tar file_to_be_extracted (1 Reply)
Hi,
I have a script (.sh file) which has been created through my login. This script executes a jar file.
Java is installed through my login and the folder has been given full permission for access.
When this script is added by root in crontab, it does not get executed.
Could you please... (1 Reply)
If I have a script that is using
unrar e file.part1.rar
How does the script get the name of the extracted file if I don't know the extension of the file?
In my example the name would be file.***, but I wouldn't know the extension.
---------- Post updated at 05:13 PM ---------- Previous... (0 Replies)
I've written the script below to merge only .txt files that exist in one directory into one huge .txt file and ignore other files with other extensions.
now the result is one huge .txt file with all the contents of other .txt files
how can i add a File Name as a comment before each file?
... (12 Replies)
Hi,
I have been trying to shoot an email with the email body to be obtained from a file.
Can someone please help me with it..
I have been trying to use the MAILX commad for the same.
mailx -s "test email" -r sender@test.com < file.txt
but it sends the file as an attachment,while i... (3 Replies)
Hi ,
I am working in Sun SOlaris 9 and trying to extract a particular jar file in my home.
I am giving command
"jar xv <filename>"
But it just hangs and does nothing ?
Any pointers why this is happenning ? or how can I see contents of a jar file?
Thanks (2 Replies)
Hello,
I recieve the following error when trying to run the following command in a ksh. The operating system is AIX5.1.
/usr/bin/jar -xvf {filename}.zip
Can't find class java.lang.System
But when I run it on the command line it unzips the file fine.
Does anybody know why this... (2 Replies)