Programming :: Program That Activates A Command-line?

Feb 7, 2010

I am wanting to write a program that runs a program or command-line. Is there are way of making a program that activates a command-line (for example executing 'ps -a -f' or '/home/shared/fah').

In addition to that, I want the program to do a 'ps -a -f' and put the results in a buff, how could I do this.

View 5 Replies


ADVERTISEMENT

Programming :: Using Command-line Options With A Program That's Called Using Env

Oct 11, 2010

I thought about this a while ago when reading through a Python tutorial and I googled some and couldn't find an answer. Now I want to know it for Ruby, also, and it's more important now because I want to invoke Ruby with -w.

How can you use:

Code:

with a -w option to ruby, like:

Code:

This doesn't work and I can't find an explanation of how to do it.

Code:

View 1 Replies View Related

Programming :: Python - Call Function From The Command Line After Compile The Program?

Dec 28, 2010

If i have a python file with a function call_me(a,b),how can I call this function from the command line ,after i compile the program?

View 5 Replies View Related

Ubuntu :: Box To Run A Command Line Program?

Sep 19, 2010

I have just installed pdfocr. Unfortunately it does not have a gui and so in time I will forget how to use it or not remember I have it.

Is there a simple generic program that will browse to where the file is and then run the command line? I suspect python will do it. Could someone point me to a suitable tutorial for this purpose.code...

View 2 Replies View Related

Ubuntu :: What Command Line Program Should Be Used

Jul 6, 2011

I am going to do a web based search for several thousand webpages which may or may not exist. I just want a list of the addresses which work. I dont want to load into firefox, and I'd preffer not to ping the url. I just want to test the URLs for validity and kick back a list of good URLs.
Any Ideas on a simple program to do this, which I can use in a bash script?

View 2 Replies View Related

Debian :: Install A Program Using The Command Line?

Jan 29, 2011

I tried to install Vlc using the terminal (terminal as root). I've used the command aptitude install vlc. Instead of installing only vlc, my gnome desktop environment was removed, gdm was removed, many more programs was removed! What's the command for installing just a single program using the command line? I was used under Ubuntu to use the command sudo apt-get install [***]

View 14 Replies View Related

Fedora :: Using Built In Command Line FTP Program?

May 13, 2010

Any relatively easy user guide for the built in command line ftp program?

View 10 Replies View Related

Ubuntu :: How To Run A Python Program From The Command Line

Jun 14, 2011

i have ubuntu 10.04 and python 2.6 installed how do i run, stop or restart a .py file from the command line.

btw im using Putty from a windows computer

View 1 Replies View Related

SUSE :: Unable To Get A Program To Run From The Command Line?

Nov 9, 2010

I have reinstalled Suse 10.1 as dual-boot with Windows XP. I am now unable to get a program to run from the Linux command line. I am familiar with the program and have had it running previously when the machine was Linux-only. Everything else, e.g.Firefox and Office, work fine in Suse.

[Code]...

The problem occurs with all commands - not just this one. isis3Startup.sh is in green on the screen so I assume I should be able to run it - I have never had any problem when it was installed previously.

View 2 Replies View Related

Software :: Command Line Program For IP Calculation?

Apr 8, 2011

ipcalc isn't the one I am thinking of. I remember another one that was a bit better, with more options -- easier to use.I remember that if you gave it a CIDR network /23 and an IP, it would list all of the address ranges, network, broadcast for that network..

View 2 Replies View Related

Programming :: Effect Of Using Eval To Execute A Command As Opposed To Writing It On The Command-line?

Jun 18, 2010

Code: cmd='date | wc'

$cmd If this script is executed, an error is generated. The reason written was that "The execution fails because the pipe is not expanded and is passed to date as an argument".What is meant by expansion of pipe. When we execute date | wc on the command line, it goes fine.then | is not treated as an argument. Why?

View 4 Replies View Related

Debian :: Any Program To Send Mail From Command Line?

Sep 9, 2010

Is there an easy to use program that I can use to send mail from the command line? I want to be able to create a batch script to send mail from different text files. What I'm looking for is something like:
mailapp mailserveraddress destinationmailaddress mymailaddress filetosend

View 11 Replies View Related

General :: See All Installed Program In Ubuntu From Command Line?

Jun 16, 2010

How can I see all my installed program in Ubuntu from command line?

View 2 Replies View Related

Ubuntu :: Difference: Run Program From Rc2.d Or From Root Command Line?

Mar 26, 2010

Example: In rc2.d I have S99test. In it: Code: #!/bin/sh mplayer -playlist "/music/Thom Yorke - The Eraser" Reboot; hear the loveliness; press pause (lirc setup)...still loveliness.

Login as root; "pkill mplay";hear nothing; "/etc/rc2.d/S99test"; more loveliness; press pause...silence! I know that i the former case, mplayer is assigned (for lack of a proper term) to a session, e.g. tty1. Not so in the latter. But why should a program like mplayer not receive (or ignore?) input from lircd, simply because it doesn't have a session? And how can I get mplayer (or any program run from boot scripts) to work with other programs (like lircd)?

View 1 Replies View Related

Programming :: Command Line Invocation Of Gnome-terminal To Run More Than One Command?

Feb 16, 2010

I am trying to learn how to pass more than a one-command startup for gnome-terminal.

I will give an example of what I'm trying to do here:

Code:
#! /bin/bash
#
#TODO write this for gnome and xterm
USAGE="
${0##*/} [-x] [-g]
code....

However, running with the -g option to invoke gnome-terminal, I get a "There was an error creating the child process for this terminal" error.

This same error occurs if the gnome-terminal line is changed to

Code:
gnome-terminal -e mcTerm

Is there any way to pass more than one command on to gnome-terminal? I have tried various single and double quoting senarios and in a final attempt, I abstracted to an exported function all to no avail. Perhaps even though gnome-term is better at many things than xterm, xterm trumps it in this instance.

View 4 Replies View Related

General :: Ubuntu - Command-line Program That Switches Consoles?

Jun 18, 2011

For whatever reason, the "Ctrl-Alt-Fn" sequence has no effect on one of my Ubuntu machines; the sequence is interpreted as ordinary input. I need to get the system to a console because I'm trying to do a dist-upgrade and that's going to bounce gdm etc.

Is there some command-line tool that can be used to switch consoles? I have some vague distant memory of that being possible.

(I'm running Ubunty Jaunty at the moment. Yes I know it's old; I'm trying to march forward.)

View 2 Replies View Related

Ubuntu :: How To Create A Shortcut To Open Command Line Program

Feb 21, 2010

I use a few command line programs quite often such as nano and mpc. I'd like to create a shortcut icon to open them rather than opening a terminal and then typing in the program name to open it. For example, how could i open konsole with nano opened in one step?

View 5 Replies View Related

Software :: Program To Hibernate The Computer For A Set Time (from Command Line)?

May 9, 2011

Is there a program I can install and run from the Command Line that will hibernate the computer (pausing all running programs (like my Minecraft server)), cutting power usage TO A BARE MINIMUM, and the un-hibernate after a set time? The laptop this will be used on is SliTaz linux with the GUI disabled (unless i run startx)

View 3 Replies View Related

Programming :: Convert This Awk Command From Command Line Into An Awk Script ?

Oct 15, 2010

I'm trying to convert this awk command from command line into an awk script, but just cannot get it to work:

This is what i have after my BEGIN

Am i missing something here? this just prints out the count for everyline, not counting lines on 5th field that match 'A'

View 1 Replies View Related

Debian Multimedia :: Finding A RSS Program That Can Run On The Desktop Command Line Style

Jun 8, 2010

I am looking for a good RSS program that can run on the desktop command line style.

View 3 Replies View Related

General :: High Level Command Line Program For Burning CDs And DVDs?

Mar 12, 2010

I'm sick of screwing around trying to script a clean solution to burn multiple files and folders to CDs and DVDs with wodim, growisofs and genisoimage.I'm looking for a high level command line program that uses sensible defaults and takes arguments something like this:[program-name] [cd|dvd] /path/to/dir1/ /path/to/dir2/ /path/to/file ...It should then do all the low level copying and ISO generation transparently and just burn the damn disk!Does anyone have any suggestions? I've looked at several programs but it seems there are too many choices to trawl through and not enough information about them online.

View 4 Replies View Related

General :: How To Program The Command Line To Run A Piece Of Code Multiple Time

Dec 4, 2010

So, I usually write/find a test case generator for any code that I write. This type of code generally leads to some file output. To be thorough, I try and generate many different files to test my code on.

Say the command is like this:

Is there a way to automate this for many different values of the parameters and generate many different files?

I tried:

I wasn't able to use the $i in the filename, and without it the command gave me no errors, but did nothing else either. I know the Unix command line is very powerful, and I have a feeling that this should be possible, but I just don't know how to do it.

View 3 Replies View Related

General :: CentOS Command-line Program To Randomly Change MAC Address?

Nov 7, 2009

OS: CentOS 5.3 Enterprise Server
Red Hat Nash Version 5.1.19.6

I need to find a command-line program to randomly change my MAC address. I know on Ubuntu there is a program called 'macchanger'. And on Windows another one called 'macshift'. I just can't find one for CentOS 5.3 Enterprise Edition.

View 3 Replies View Related

Ubuntu Networking :: Program Transmits Whole Graphical Interface Slowly - Command Line With Computers

Jan 18, 2011

I need to use some PCs located on my university from home through the internet. I am using a program called Teamviewer [URL]... The problem is that this program transmits the whole graphical interface, which is slow, but I just need to use the command line with these computers. I am aware of ssh, but my university won't give me access to theses computers over the internet.

View 9 Replies View Related

Ubuntu Servers :: Use The Mail Command Line Program To Occasionally Send Log Output To Email Aliases?

Jan 27, 2011

Can anyone tell me what the pros and cons are between heirloom-mailx vs mailutils? This is for ubuntu 10.04 LTS. AT this point my only purpose is to use the mail command line program to occasionally send log output to email aliases.

View 2 Replies View Related

Programming :: Awk - Input From One Line - Execute Program - Input From Next Line - Execute Program

Sep 25, 2010

I have a file with two fields of numbers that I want to use as input for another program.

Code:

The above code does not work, as I think it would take the whole first and second fields as the input for one particular instance of the program 'inputbashangle'. What I want is to get the first two numbers from the first line of the file 'outfailtest', execute 'inputbashangle' with them, then move on to the first two numbers of the second line for all the lines of 'outfailtest'.

View 9 Replies View Related

General :: Command Line - Unix - Program That Can Handle All Popular Compression/archiving Formats - E.g.tar, Gzip, Bzip2, Zip?

Jun 22, 2011

I sometimes get confused by the varying command line options I need to run common Unix archiving and compression software (e.g. gzip, bzip2, zip, tar).

Is there a program out there that can just Do What I Mean for common cases? For example:

View 2 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 :: Compile C++ Program Without Changing #include Line & Header Files Not System?

Apr 3, 2011

I have C++ source code(*.cpp) files that expects it's header files in System's include folder which is/usr/include.The cpp files has include lines like this:

Code:
#include <some.h>
#include <another.h>

[code]...

View 3 Replies View Related

Programming :: Create A RS232 C Program That Executes A Series Of Commands Down The Line To A Robot?

Jan 5, 2011

I am trying to create a RS232 C program that executes a series of commands down the line to a robot. Everything seems to work fine, except any sequential write to the serial port. At first I thought it was the UART's buffer being filled too fast, but even with a 50 uS delay it still throws the error.

Here is my code:

Code:
#include <termios.h>
#include <stdio.h>
#include <unistd.h>
#include <fcntl.h>
#include <sys/signal.h>
#include <sys/types.h>

[Code]...

View 1 Replies View Related







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