10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
In the awk piped to sed below I am trying to format file by removing the odd xxxx_digits and whitespace after, then move the even xxxx_digit to the line above it and add a space between them. There may be multiple lines in file but they are in the same format. The Filename_ID line is the last line... (4 Replies)
Discussion started by: cmccabe
4 Replies
2. UNIX for Beginners Questions & Answers
In the awk below I am trying to remove all lines above and including the pattern Test or Test2. Each block is seperated by a newline and Test2 also appears in the lines to keep but it will always have additional text after it. The Test to remove will not. The awk executed until the || was added... (2 Replies)
Discussion started by: cmccabe
2 Replies
3. Shell Programming and Scripting
Hello,
I wrote several scripts that work with job arrays (sbatch) that look like this:
#!/bin/bash
#SBATCH --partition=carl.p
#SBATCH --ntasks=4
#SBATCH --time=0-10:00
#SBATCH --mem-per-cpu=48G
#SBATCH --job-name=basic_test
#SBATCH --mail-type=END,FAIL
#SBATCH --mail-user=
#SBATCH... (2 Replies)
Discussion started by: idbemad
2 Replies
4. Shell Programming and Scripting
Hi,
Could you please help me finding a way to replace a specific value in a text block when matching a key pattern ?
I got the keys and the values from a command similar to:
echo -e "key01 Nvalue01-1 Nvalue01-2 Nvalue01-3\nkey02 Nvalue02-1 Nvalue02-2 Nvalue02-3 \nkey03 Nvalue03-1... (2 Replies)
Discussion started by: alex2005
2 Replies
5. Shell Programming and Scripting
I have the following file I wanted to convert mutiple spaces to tab:
I tried cat filename | tr ' ' '\t' or sed 's/ */ /' FILE
but it looses the format
5557263102 5557263102 5552074858 5726310211 5557263102 5557263102
5557263103 5557263103 2142406768 ... (2 Replies)
Discussion started by: amir07
2 Replies
6. Shell Programming and Scripting
Hi,
Please help to fetch the values for a key from below data format in linux.
Sample Input Data Format
11055005|PurchaseCondition|GiftQuantity|1
11055005|PurchaseCondition|MinimumPurchase|400
11055005|GiftCatalogEntryIdentifier|Id|207328014
11429510|PurchaseCondition|GiftQuantity|1... (2 Replies)
Discussion started by: mohanalakshmi
2 Replies
7. Shell Programming and Scripting
Hi,
I have a file with following pattern. We are looking to filter out only specific content from this file.
sample
BLAdmins Server.*
LinuxAdmins Server.*
Policy Name: Recommended Default ACL Policy
Everyone ACLPushJob.Read
Everyone ACLTemplate.Read
Everyone ... (9 Replies)
Discussion started by: Litu19
9 Replies
8. Shell Programming and Scripting
Input file
matrix-remodelling_associated_8_
aurora_interacting_1_
L20
von_factor_A_domain_1
ATP_containing_3B_
.
.
Output file
matrix-remodelling_associated_8
aurora_interacting_1
L20
von_factor_A_domain_1
ATP_containing_3B
.
. (3 Replies)
Discussion started by: perl_beginner
3 Replies
9. Shell Programming and Scripting
Hi,
I have requirement that I need to split my input file into two files based on a search pattern "abc"
For eg. my input file has below content
abc
defgh
zyx
I need file 1 with
abc
and file2 with
defgh
zyx
I can use grep command to acheive this. But with grep I need... (8 Replies)
Discussion started by: sbhuvana20
8 Replies
10. Shell Programming and Scripting
Input file:
>TRACK: Position: 1 TYPE: 1 Pos:
SVAVPQRHHPGGTVFREPIIIPAIPRLVPGWNKPIIIGRHAFGDQYRATDRVIPGPGKLE
LVYTPVNGEPETVKVYDFQGGGIAQTQYNTDESIRGFAHASFQMALLKGLPLYMSTKNTI
LKRYDGRFKDIFQEIYESTYQKDFEAKNLWYEHRLIDDMVAQMIKSEGGFVMALKNYDGD
>TRACK: Position: 1 TYPE: 2 Pos:
FAHASFQMALLKGLPLYMS... (8 Replies)
Discussion started by: patrick87
8 Replies