Ubuntu :: Interactively Operate With Program Using Bash?

Nov 3, 2010

how to interactively operate with program using bash? such as program would ask user to select choice between "a/b/c" and then input enter to confirm? i know i could use

program << EOF
a
EOF

to choise "a", but how to input "enter", so that i could call this program in my script.

View 5 Replies


ADVERTISEMENT

General :: Make A Script To Open A Program Then Operate Within That Program?

May 7, 2010

I am new to linux and am trying out script writing. I am using shell. How can I make a script to open a program then operate within that program?

View 5 Replies View Related

Programming :: Bash Script That Will Operate On All Files In A Directory?

Jul 22, 2011

I have about 50 files that the script will operate on, they are all located in the same directory.I need a bash script that will operate on all files in a directory. The script needs to add two lines to the beginning of each file based on the file name, and one line to the end of the file.A file named myfile.h should add these two lines to beginning of the file:

Code:
#ifndef MYFILE_H
#define MYFILE_H

[code]....

View 5 Replies View Related

Programming :: Program A SH - Bash Program With Zenity To Play Radio Based On A Site?

Feb 15, 2011

I will have to code this. However I am lacking of time since I have too much to do. make a short code bash/dash to prompt the country with Zenity, then, get the PLS or m3u url and prompt with another zenity which radio to play. http://www.listenlive.eu/index.html

My code to get url's radio country.htm is:

Code:

View 2 Replies View Related

Debian :: Start Bootchartd Non-interactively Each Time?

Apr 19, 2011

want to use bootchart to see how much time its taking for things to load up and the desktop to settle. I am having a little trouble figuring out how to make sure that bootchard loads up each time (non-interactively) so I can easily put up the results and see what could be done better. The man page of bootchartd says :-"bootchartd is commonly used to profile the boot process for the purpose of speeding it up. In this case, it is started by the kernel as the init process. This is configured by adding the init=/sbin/bootchartd option to the kernel command line -- either interactively or by editing the bootloader's configuration file. Please refer to the documentation of your bootloader for details (e.g. lilo, grub or yaboot)."

View 2 Replies View Related

Server :: Adding A Host To Known_hosts Non-interactively?

Mar 9, 2011

I have an automated setup (debian) which includes a startup script that rsyncs to a server (always the same server). Everything works well - just that I have to manually confirm that the host is supposed to be added to the known_hosts

Code:
The authenticity of host 'myserver.com (xx.xx.xx.xx)' can't be established.
RSA key fingerprint is 9b:ee:a6:47:hb:92:ac:76:81:94:18:7d:ad:8c:3e:25.

[code]....

View 2 Replies View Related

Ubuntu :: Bash Script That Runs A Program N Times?

Oct 20, 2010

A bash script that runs a program N times, takes the numbers program produces (each time different) and calculates the average of those numbers.

View 2 Replies View Related

Debian :: Bash Script As A Program?

May 21, 2011

Is there a way to have a bash script run as a program so you can start it like how you would run apt-get?

View 2 Replies View Related

General :: Use Bash Shell When I Run A Program From It?

May 11, 2011

So I open firefox from my bash shell with:

Code:
firefox google.ca
it opens firefox, I can browse, etc.
Now if I alt-tab back into my shell, i can't enter any commands in the shell.

I know that i can do this if I close firefox, but I want to keep working in my shell with firefox still open.

Is this possible?

View 6 Replies View Related

Programming :: Run A C Program From Bash Script?

May 9, 2010

I'm trying to write a bash script that helps me building C program then run the C program but I don't know how to make it run.I did like this

Code:
#!/bin/sh
# assuming I've built C program '$output' successfully

[code]....

View 5 Replies View Related

Software :: Correct Output From Script Appears Only When Script Is Run Interactively?

Jan 15, 2009

I have a script on several of our systems that runs a series of checks, and e-mails the results to the system administrator. The workstations in question are running a derivative of Fedora Core. The code for the script is listed below.

Code:
#!/bin/bash
# This script will run the df and uptime commands,

[code]...

View 2 Replies View Related

Programming :: Sort IP Addresses For A Bash Program?

Apr 29, 2010

I have for example the following IP addresses:

24.172.220.218
41.239.36.19
63.215.202.234
66.176.124.22

[code]....

How can I sort those IP addresses? I want to sort them using the first 3 numbers I also want to count the number of times that address is repeated This is a batch program.

View 4 Replies View Related

General :: SSD Trim Simple Bash Script Program?

Jul 9, 2011

I wrote this script which works but it should run automatically about once per week. I hunted and experimented with KDE Task Scheduler (no dice and no help anywhere) and cron (confusing instructions and cannot edit crontab -e with vim, and cannot enter cron folders/files). I would settle for a desktop shortcut to run the script but found no for that.

Script:

Code:

#!/bin/bash
xterm -hold -e fstrim -v /
Machine:
OS: openSUSE 11.4 x86_64

[code].....

View 13 Replies View Related

Programming :: Can't Pass Variables To A Program In Bash Script / Fix It?

Dec 30, 2010

Trying to do a simple bash script, and having some issues. I am relatively new to bash, and did my best to search, but idk what exactly to search for.

Doesn't work code...

View 6 Replies View Related

Ubuntu :: Will 10.04 Operate Using Kernel From 9.04

Sep 1, 2011

I've used Jaunty since it came out have been quite happy with it. However, it is no longer supported and I can't access updates. When 9.10 came along, I tried to install it but found my system would randomly freeze. In fact, it randomly freezes with 10.04 as well. I tried Linux Mint's equivalent to Ubuntu's 9.10 and 10.04 and have the same problem. I've visited discussion boards and see that this is a huge problem for many Ubuntu users --- but I've never found a solution that works.

I assume the problem is in the kernel and am interested in seeing if 10.04 will run on that kernel version. My questions are these:

a) Is my conclusion that the source of my problem is the kernel a reasonable conclusion to reach?

b) If the conclusion is reasonable, is it possible to run 10.04 using the same kernel that 9.04 came in?

c) If the answer to C is, "Yes," then is there a tutorial that will walk me through how to install kernels?

View 2 Replies View Related

Ubuntu :: Get Windows To Operate On Desktop?

Apr 12, 2011

I cant seem to get Windows to operate on my desktop

View 4 Replies View Related

Programming :: Write A Bash Script Program In System Command Terminal?

Mar 22, 2010

I'm trying to write a bash script program in the Linux command terminal that will write to a fellow user and then continue reading down the program. this is what i have (kind of explains the idea too):

#!/bin/sh

clear
echo "this is before the write command"
write jcummins
this message should go to jerry
echo "the message didn't send and this string will not appear"
echo "it appears it has stopped at the write command"

View 5 Replies View Related

Ubuntu :: Files Are Corrupted And Will Only Operate Kubuntu ?

Apr 16, 2011

I recently downloaded a copy of Kubuntu from the official website...when i finished downloading it and tried to run it inside windows, my virus scanner immediately picked up several malware inside temp files in my computer called win32 antivirus. I attempted to install kubuntu on my computer on a partition (i've previously done this on other computers no issues) but it had multiple partitions. Instead i tried to do a clean install of kubuntu then attempt to install vista again then. However it is now telling me my files are corrupted and will only operate Kubuntu. This is not what i want, i wanted to operate both on partitions as i haven't completely figured out how to use kubuntu?

View 1 Replies View Related

Ubuntu Multimedia :: Operate Banshee W/ The Terminal?

Jul 4, 2011

what i mean is like type "banshee play Hatsune_Miku" and it plays...... and google yield no results so i brought it here.

View 4 Replies View Related

Programming :: Changing A Line In A Config File While Installing The Program Using Bash Script

Jul 22, 2011

I am trying to write a bash script that installs a program fully automated for me. I am stuck at the one part where i need to change a line in one config file. I have tried various syntax for sed and none have worked. Maybe someone can suggest how to go about this. Since the line appears in the middle of the file, I can't use echo or cat. Also the file will be diffrent lengths depending on the install.

The line I need changed is:

I need that changed to:

the last syntax i tried is:

Yes this is for PNP4Nagios on centos 5.6 64bit. If i can get this figured out. I will be willing to post the whole thing for others to use. it will be used to install PNP after a working nagios install is done.

View 11 Replies View Related

Programming :: Talented Coder To Program Bash / Perl App That Plays SWF On HTML Page?

Feb 10, 2011

Everyone knows that it is like impossible to use mplayer to watch an *.html file. OK.

For instance here is a cool example of lot of streaming for firefox
http://watchtvlivestreaming.com/tvlive/b5499

Code...

Anyone is there a talented bright coder, coming from hell -because it is really difficult, to make such console program ?

View 1 Replies View Related

Debian :: Cannot Operate Veracrypt

Feb 12, 2016

I am unable to run Veracrypt on Debian 8.3 64 bit. Yet I have applied the installation procedure.

I downloaded the 1.16-veracrypt-setup.tar.bz2 archive and I unpacked in a directory veracrypt I created in my home.

I get 4 files: veracrypt-1.16-console-setup-x64; veracrypt-1.16-console-setup-x86; veracrypt-1.16-setup-gui-x64; veracrypt-1.16-setup-gui-x86

I keep 2 that match my 64-bit architecture, ie: 1.16 veracrypt-console-setup-and-x64-veracrypt 1.16-setup-gui-x64.

I log in as root in the terminal. I slip the veracrypt-1.16-setup-gui-x64 file. Validate the installation choices by default. After completing the installation, I see the icon Veracrypt and when I click on the Veracrypt application does not start.

View 5 Replies View Related

Ubuntu Servers :: Possible To Operate Web Server 'without' Registering Domain Name

May 14, 2011

I'm wondering if it's possible to operate a Web Server 'without' registering a domain name, using an IP address alone.I currently have Apache & Tomcat running on one of my workstations. I am currently using these servers as development sandboxes; and I have P2P Search Engine 'YaCy' running under Apache, which is accessible from the outside to the entire P2P network.

Since my Apache server is accessible from the outside, I was thinking that I might setup one of my other workstations as a server with just my 'external' IP address & port number as a way of reaching my site, i.e. http:// 255.183.47.201:8090/. I can't see any reason why this wouldn't be possible. I seem to remember several of my former companies doing this on their corporate Intranets. Also, I wouldn't be locked into registering a domain name every year; and I wouldn't have to worry about any content restrictions. If my intended audience knows where to find me; I can't see any reason why this wouldn't work. And, I don't see why my site couldn't be indexed by search-engines. The only caveat I can think of is making sure I have enough bandwidth from my ISP to support the anticipated traffic.If this will work, I assume I can setup a regular website, an online store, podcast, or provide any other type of tradional web-service this way.

View 5 Replies View Related

OpenSUSE :: 11.3 - Keyboard In XEmacs Do Not Operate

Nov 22, 2010

I was experimenting with Emacs and Xemacs - trying to chose between them. Finally I've re-installed Xemacs and find that keyboard in Xemacs don't operate.
I'm using openSuSE 11.3
Emacs 23.1.1
Xemacs 21.59....
Perhaps I should uninstall Emacs?

View 3 Replies View Related

Hardware :: What Machine Type Operate On

Jan 18, 2011

I need to know what hardware machine underlines my linux. I have machine e.g. IBM X3550 and I need to get this info from linux.

View 4 Replies View Related

Slackware :: Freezes After Certain Screensavers Operate For A While?

Nov 7, 2010

So I've been using Slackware for a long time but I'm not really sure where to start with this bug. Basically I'm on an old P4 Dell system that I just got for free (so semi-old hardware)

Code:
bash-4.1# lspci
00:00.0 Host bridge: Intel Corporation 82845 845 [Brookdale] Chipset Host Bridge (rev 04)

[code]...

View 9 Replies View Related

OpenSUSE Network :: 11.4 New Install, How To Operate Firewall?

May 25, 2011

I have done a new install of 11.4 and as with previous versions, I have to go to YAST2 and disable the firewall before I have internet and local network access. Finally I must find out how to do this correctly.

How to I change the default firewall to allow me internet and local network access without disabling it completely? Also I am unclear about the function of Novel Network Armor? What does this do?

View 9 Replies View Related

Installation :: Create A Cd Or Usb To Boot And Operate On A System?

Apr 25, 2010

is there a way to create a cd or usb to boot and operate on a system with just ram and another solid state usb how custom the script??

View 2 Replies View Related

Networking :: Operate Vodafone E220 Modem On FC 13?

Nov 6, 2010

I have installed the 3 following pakages of Fedora 13 ozerocdoff-0.4-1.fc11.i386.rpm usb_modeswitch vodafone-mobile and after that I have given the command

vodafone-mobile-connect-card-driver-for-linux-debug

all I see after that :

vodafone-mobile-connect-card-driver-for-linux-debug
/usr/lib/python2.6/site-packages/twisted/persisted/sob.py:12: DeprecationWarning: the md5 module is deprecated; use hashlib instead

[Code]....

GConf Error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See [URL] for information. (Details - 1: Failed to get connection to session: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.)

View 2 Replies View Related

General :: Operate NTFS Partitions From The OS On The Same Machine?

Jul 15, 2010

i have a window xp////on the same machine i installed linux mint9.....mostly i am using linux mint9.....i want to operate my NTFS (Window XP) Partitions from linux mint9..

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved