Bash function to suppress warning message for specific text and display prompt
In the below bash function multiple variants are input and stored in a variable $variant, and each is written to an out file at c:/Users/cmccabe/Desktop/Python27/out.txt stored on a separate line.
contents of out.txt
Each individual variant then goes through functions nomenclature, check, and convert.
The bash below runs as is, but I need to modify it to account for if a line in variant has a +/- in it (like line 1 does, NM_003924.3:c.242-1G>A).
The +/- always occurs in the same location (that is right before the last number in the c. and first letter before the > in the line but can vary in the amount of digits.
After the nomenclature function runs a out_name.txt is created at C:/Users/cmccabe/Desktop/Python27/out_name.txt and looks like the below:
I am trying to add a condition that will suppress the warning message $2 for the line in bold.
In addition, that line "is an intronic variant" is displayed. My attempt to incorporate these changes is below in bold, I hope it is a start. I apologize for the long post, just trying to include enough detail. Thank you .
moderator please close as i am going to repost a cleaner thread. Thank you.
Last edited by cmccabe; 03-09-2017 at 12:53 PM..
Reason: added moderator comment
Hi,
I'm running a background job in my bash script.
But when the job quit, bash echos a message like
"+ Done xterm".
This is annoying.
How can I suppress it? (5 Replies)
I'm creating a bsh shell to unzip a file from one directory into another. The directory that holds the zip files has zip files constantly being added to it, so I am testing it before it does the unzip and more.
Right now my code looks like this:
unzip -tq $ZIP_PATH/$ZIP_NAME >/dev/null
if ... (5 Replies)
Hi Friends,
I am using HP-UNIX(ksh). I want to print a message at specific line on the prompt screen. For Example:
for num in 1 10 3 145
do
echo $num // need to print this on the same line for each number
sleep 2
done
Actual Output:
==========
1
10
3
145
Expected Output:... (5 Replies)
I am attempting to insert multiple lines of text into a specific place in a text file based on the lines above or below it.
For example, Here is a portion of a zone file.
IN NS ns1.domain.tld.
IN NS ns2.domain.tld.
IN ... (2 Replies)
Hello,
I am teaching myself shell scripting and I was wondering if there was a way to rename a file and display a warning or prompt message? And if you had a file like
/home/me/blah/ for example, what are the ways to use the CD to get to /me?
Would it be ../home/me? Are there other ways to... (4 Replies)
I'm having trouble with part of this bash script in Linux where I respawn a new instance of script and kill the old one to prevent forking (Yes, I know 'exec' will not fork but this needs to be interactive) When the old instance is kill it pops up "Terminated!" in the middle of the new instance... (7 Replies)
I have a variable strLst containing a list of strings. I want to create a function that takes the list and an error message. If the number of strings is 0 or greater than 1, I print the error message. (1 Reply)
Hello All,
My question has to do with a Remote Desktop Session going from my Linux HOST to a Windows GUEST.
Linux OS: OpenSuSE 11.4 i586
Windows OS: Windows Server 2003
For some reason after I have run rdekstop to connect to the Windows Guest, whenever I click on the Shift key I get the... (0 Replies)