Ubuntu :: When Do Echo $playerId Have Always A Number Ex. 32812. So It's Never Empty?

Jul 31, 2011

ok i have a problem with "if" condition:

Code:
#!/bin/bash
playerId="0";

[code]....

View 3 Replies


ADVERTISEMENT

General :: Command Not Found For All But PWD And Echo - Path Empty

Mar 1, 2011

I logged into my Red Hat Enterprise Linux machine at work (use it for software development) and the primary GUI does not load. Instead, widgets appeared for xclock, xterm, and Firefox. In the terminal, I start typing in commands to try to figure out what's going on, but all commands are not found except pwd and echo. I 'echo $PATH' and that returns just an empty, blank line. 'echo $SHELL' lets me know I'm using cash.

The likely cause was my attempt to install Adobe Reader Firefox plugin yesterday. After it downloaded, I ran the binary but Firefox didn't seem to recognize that I had installed it, so I went into my .cshrc file and added the adobe folder to the path. That didn't seem to work, so I gave up, deleted the binary and the folder I installed to, and removed that directory from the path in the .cshrc file. This last thing (the export PATH line in that file) I'm certain is back exactly as it was before.

I have successfully added the /bin and /usr/bin back to the path from command line via
setenv PATH /usr/bin:/bin
but of course it doesn't stick after reboot nor does it magically load the primary GUI. I'd rather not go through the effort of creating a ticket for our company's Global Service Desk cuz there's no telling how long that could take to resolve. In the meantime, I can't do any programming.

View 23 Replies View Related

General :: $echo Cat Vs $cat Echo / Difference Between Them?

Dec 16, 2010

What is the difference between

$echo cat
$cat echo

View 1 Replies View Related

General :: Shell Scripting \ (test If A File Is Empty, If It Is Then Display "file Is Empty" Otherwise Display "file Is Not Empty")?

Oct 5, 2010

I am a final year student doign Computer systems engineering and just been introduced to linux. While still strugling to catch up with the commands, I am now given an assignment under shell scripting.I seriously am strugling to understand this question, can you please assist me.Here follows the assignment:

Operating Systems III
Some tips
e.g. (test if a file is empty, if it is then display "file is empty" otherwise display

[code]....

View 10 Replies View Related

Ubuntu :: Get The Card Number And Device Number On System For Attched USb Audio Device?

Oct 1, 2010

how to get the card number and device number on system for attched USb audio device?

View 3 Replies View Related

General :: Unix Ps -l Priority Whoes One Number In Column "PRI" But In Same Time Ps -o Pri Shows Another Number?

May 21, 2011

Why does unix ps -l whows one number in column "PRI" but in same time ps -o pri shows another number? cpu and nice are zero for those processes

View 1 Replies View Related

Ubuntu :: Playing With Tty And Pty (echo And Cat)?

May 11, 2010

I've read a bit about pseudo terminal but I still don't get it fully, I've found a really sweet article:

[URL]

I thought the two end tty and pty were acting like a pipe so while testing, I opened two terminals:

terminal1: cat /dev/ptyq9
terminal2: echo "test" > /dev/ttyq9

And it worked, terminal 1 printed: "test". But if the pipe is bi-directionnal ( as terminal were echoed back what user was typing), I was expecting to be able to go the other way around:

terminal1: cat /dev/ttyq9
terminal2: echo "test" > /dev/ptyq9

It does not work ! Echoing on pty just terminates the cat on pty. How is the "return" working them ?

View 1 Replies View Related

Ubuntu :: Returns 0 To The Shell And Echo $? Gives 0?

Sep 1, 2010

check the following program
/*a.c*/
int main()

[code]....

View 1 Replies View Related

Ubuntu :: Echo Password When Entering In Rar?

Dec 28, 2010

When I use rar e to extract a rar file, the request for entry of the password always says password will not be echoed. For longer passwords, this is difficult, since a single mistyped key will result in an error.

Does anyone know how I can use the rar command to extract and have the password echoed (appear on the screen as I type it)?

View 2 Replies View Related

Programming :: Echo Some Value Using Awk?

Jun 17, 2009

I am trying to echo some value using awk, and for reading the file i am using cat command. If there no space in the file content then the following script result correctly.

console: # cat 1
one;two;three;
four;five;six;

[code]....

In case any space is there in the file 1 then i am facing the problem in the output value

console: # cat 1
o ne;two;three;
four;five;six;

[code]....

View 5 Replies View Related

Ubuntu :: Right Padding In Echo Of Shell Script?

Mar 22, 2010

I'm a n00b in shell scripting,echo "$num $den $file" is the current formatI need 10 right padding for each term above in the above where $num & $den is of %d type, whereas $file is %s type.

View 2 Replies View Related

Ubuntu :: Echo Command To Output First Argument

Nov 5, 2010

In a script, when I enter "echo $1" the first argument is outputted. When I enter:
a=1
echo "$$a"

The output is just "$1", not the first argument. If I enter:
a=1
b=$$a
echo $b

The output is still "$1" and not the first argument. How can I get echo to output the first argument without use "$1" directly?

View 4 Replies View Related

Ubuntu :: Startup Scripts / How To Echo To Screen

Feb 2, 2011

I have ubuntu desktop 10.10. I wrote a simple script that I want to execute at system startup. The only problem I have (and one that I've been struggling with for the better part of the day) is that I don't see the outputs of the script during startup.

View 1 Replies View Related

Ubuntu Multimedia :: Audacity Pre-echo Removal?

May 15, 2011

I was using a line device to record compact cassettes to digital (Linear PCM) then I transferred these files to the computer.Due to cassette print-through, there is audible, albeit weak, pre-echo. This is not caused by the recorder since I can hear them playing the cassettes on a deck.So. Does Audacity have a pre-echo removal function, or can a similar result be obtained by applying different effects? Or any 3rd-party plug-ins?

View 1 Replies View Related

General :: Echo An '-n' Without A New Line?

Oct 19, 2010

how to echo an '-n' without a new line?

View 8 Replies View Related

Programming :: What Exactly Does Echo $0 Return

Jan 18, 2010

I'm confused about what "echo $0" in a shell actually return. Consider these tests:

Code:
[root@e11apvl151 ~]# # Login shell:
[root@e11apvl151 ~]# echo $0
-bash
[root@e11apvl151 ~]# # Starting a new shell
[root@e11apvl151 ~]# bash
[root@e11apvl151 ~]# echo $0
bash
[root@e11apvl151 ~]# screen
[root@e11apvl151 ~]# echo $0
/bin/bash

Depending on wether the shell is a login shell, a regular shell, or a screen utility, I get different results.

View 8 Replies View Related

Ubuntu :: Compiz - Visual Echo On Cube Rotate

May 7, 2010

Here's a strange compiz effect - odd visual echo when you rotate the cube. I kept my /home partition from the Lucid beta testing and compiz seems to have problems with it - looks like I will have to do a complete format and reinstall to solve this. I already purged and reinstalled compiz and anything I could find associated with it. Anyone else suffering from a buggy compiz? The strange thing is - this only occurs 1 out of 10 boots???

View 4 Replies View Related

Ubuntu :: C++ - Use System To Call Echo And Pass Variables?

Sep 7, 2010

I'm trying to use system to call echo and pass variables to it. That was a success. The problem is the variables inside the while-loop i wrote cannot be manipulated. what I'm doing wrong here? here's the code:

Code:
#include <iostream>
#include <stdlib.h>
#include <string>
#include <sstream>

[Code]....

View 7 Replies View Related

Ubuntu Multimedia :: X-Fi Titanium Microphone Feedback (echo)?

Oct 12, 2010

I'm running Maverick right now, but the problem also occurs with Lucid. My sound card is a creative X-Fi Titanium (emu20k2). Audio playback is fine, surround is fine, etc. Audio capture is "fine" too - the problem is that the microphone picks up everything that the headset is outputting. This is very strange since the headset is a noice-cancelling headset and in order for that to happen on other platforms (windows) I essentially have to turn the volume up to astronomical levels. As always, this doesn't happen on windows.

Needless to say this poses somewhat of a problem with VoIP applications since folks I'm interacting with constantly hear themselves echoed back by me. The only solution is to tune down the microphone volume but that adds another problem: people can no longer hear me clearly.

So my question is: is there a way to enable echo reduction for Pulse Audio so that the mic doesn't constantly capture what's coming from the outputs? And yes - when I look at the "input" tab in the sound preferences application I can see the marker move if I speak - same with pavucontrol

View 1 Replies View Related

Ubuntu Multimedia :: Get Echo Sound From Microphone To Speakers?

Nov 26, 2010

How can I echo the sound from the microphone to the speakers?

I.e., anything that is picked up by the microphone is played on the speakers immediately, without recording anything. Preferably with the ability to increase the volume.

View 3 Replies View Related

Ubuntu Multimedia :: Reduce Echo In Audio Files?

Mar 7, 2011

Do you know if there is anyway to reduce the echo in audio files, by using Cinelerra, Audacity or whatever....Online, I haven't found incoragins answer...hope something better can come up from the forum.

View 1 Replies View Related

Ubuntu Servers :: Cron Doesn't Echo To File?

Mar 27, 2011

I have a script, echoSmart.sh:

Code:
#!/bin/bash
smartctl -a /dev/sda > /smartlogs/sda-$(date).txt

[code]....

View 3 Replies View Related

Debian :: Can Record But Can't Echo Input

Jun 28, 2015

I can play audio in my alsa system and I can record. To keep things simple, I use arecord to record and aplay to play. So far so good. The problem is, I cannot hear what I am recording as I record it. Is there some way to get the input to be echoed to the output? I would optimally like to be able to do this before recording as well as during, so that I can check the levels, find the part to record on the tape, beforehand.

I have tried a test of my card: I had aplay running in one term and arecord running in another. They both ran fine and when I checked the just-recorded file, it was different audio from what I had been playing. This would indicate that the card is able to input and output at the same time, I think? I've done the usual googling as well as reading through URL... and I have done many passes of trial-and-error on my .asoundrc. The more I look at my .asoundrc, the more it looks like it should be doing what I want, but it is not.

My .asoundrc (which again, does works but does not echo audio input):
Code: Select all# pros: this allows playback and record.  Playback of several
# programs at the same time works (their outputs are mixed
# together, mono and stereo mixed to stereo)
#
# cons: input is never echoed!

[code]....

View 1 Replies View Related

General :: How To Echo Redirected Stdin

Sep 26, 2010

I execute an application from a script file and redirect stdin to it from here-doc like this:

my_cli << HERE_DOC
enable
configure
10
exit
exit
HERE_DOC

This works as expected, but I don't see neither the input nor the app output. The application is an interactive prompt written in C. When I interact manually with it, I see the prompt itself and responses to my input, but when I execute the aforementioned script I see nothing. I would like it to print the input and the output as if a real user was typing. Do you know how to achieve that?

View 3 Replies View Related

General :: How To Echo The File To Stdout

Sep 26, 2010

I have a process which logs output to log.txt. If I want to see the process's status in real-time, is there a way to echo that output to stdout instead of opening the log in a text editor and constantly reloading?

View 3 Replies View Related

General :: What Does Echo $$ Give As Output

Nov 28, 2010

What does echo $$ give as output?

View 3 Replies View Related

General :: Echo Function In .bashrc?

Feb 25, 2010

I'd like a function in my .bashrc file that would allow me to pass text to it and echo the text to a specified file. I know it's simple as "echo 'text' >> file," but ideally, I would want to alias the function so I execute something like:

Code:
user~ $ write 'this is a test' with "write" being the function, and 'this is a test' being echoed to the file. I hope I explained that well enough.

View 3 Replies View Related

Programming :: Echo Hello Command Does Not Return

Jan 11, 2010

I am testing the serial ports on a Single Board Computer(SBC) running Linux kernel 2.6.29. I usually do this by connecting the serial port to another PC serial port, then doing "cat /dev/ttyS0" on PC and "echo hello > /dev/ttyS0" on the SBC. However in the current system, "echo hello > /dev/ttyS0" command does not return at all! Also no characters appear on the destination port. I am running the echo command as root. The system boot messages show that the serial port in indeed /dev/ttyS0.

View 2 Replies View Related

Programming :: Prevent Echo As Return Value?

Jan 25, 2010

I have always encountered this problem in ubuntu bash shell scripts that echo command in a function will be treated as a return value when used in a function. e.g.

[code]...

The output would simply be xyz. Hence the echo seems to function as a "return" command when used in a function with a return value.

View 4 Replies View Related

Programming :: Difference Between PHP Echo() And Print()?

Dec 1, 2010

What's the difference between PHP echo() and PHP print(), especially in the execution time?

View 6 Replies View Related







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