05-27-2016
I apologize for the typo.... it may be easier to include all
0/0 or 1/1 or 2/2 as hom. The other condition is
0/1 or 1/2 is het . I think these are all the possibilities. Thank you
.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
using sed to replace a specific string on a specific line number using variables
this is where i am at
grep -v WARNING output | grep -v spawn | grep -v Passphrase | grep -v Authentication | grep -v '/sbin/tfadmin netguard -C'| grep -v 'NETWORK>' >> output.clean
grep -n Destination... (2 Replies)
Discussion started by: todd.cutting
2 Replies
2. Shell Programming and Scripting
Hello!
I need to delete one line in a file which matches one very precise instance of a string only. When searching the forum I unfortunately only found a solution which would delete each line on which a particular string occurs.
Let's assume I have a file composed of thousands of lines... (4 Replies)
Discussion started by: Black Sun
4 Replies
3. Shell Programming and Scripting
Say the input was as follows:
Brat 20 x 1000 32rf
Pour 15 p 1621 05pr
Dart 10 z 1111 22xx
My program prompts for an input, what I want is to use the input to locate a specific field. Like if I type in, "Pou" then it would return "Pour" and just "Pour"
I currently have this line but it is... (6 Replies)
Discussion started by: Bungkai
6 Replies
4. Shell Programming and Scripting
I'm trying to update a text file via sed/awk, after a lot of searching I still can't find a code snippet that I can get to work.
Brief overview:
I have user input a line to a variable, I then find a specific value in this line 10th field in this case. After asking for new input and doing some... (14 Replies)
Discussion started by: crownedzero
14 Replies
5. Shell Programming and Scripting
Hi,
I have an issue to combine multiple lines of a file. I have records as below.
Fields are delimited by TAB. Each lines are ending with a new line char (\n)
Input
--------
ABC 123456 abcde 987
890456 7890 xyz
ght gtuv
ABC 5tyin 1234 789
ghty kuio
ABC ghty jind 1234
678 ght
... (8 Replies)
Discussion started by: ratheesh2011
8 Replies
6. Shell Programming and Scripting
Hi,
I want to achieve something similar to what described in another post:
The difference is I want to add the line if the pattern is not found.
File 1:
A123, valueA, valueB
B234, valueA, valueB
C345, valueA, valueB
D456, valueA, valueB
E567, valueA, valueB
F678, valueA, valueB
... (11 Replies)
Discussion started by: jyu3
11 Replies
7. Shell Programming and Scripting
Hi All,
I'm having a hard time finding a starting point for my issue. I have a 30k line file (fspsec.txt) that I would like to parse into smaller files based on any character existing in field 1.
ACCOUNTANT LEVEL 1 (ACCT.ACCOUNTANT)
OPERATORS: DOEJO (418)
TOOLS: Branch Maintenance
... (2 Replies)
Discussion started by: aahlrich
2 Replies
8. Shell Programming and Scripting
In the perl below, which does execute, I am having trouble with the else in Rule 3. The digit in f{8} is extracted and used to update f accordinly along with the value in f.
There can be either - * or + before the number that is extracted but the same logic applies, that is if the value is greater... (5 Replies)
Discussion started by: cmccabe
5 Replies
9. Shell Programming and Scripting
I have been reading old posts and trying to come up with a solution for the below: Use a tab-delimited input file to assign
point to variables that are used to update a specific field, Rank. I really couldn't find too much in the way of assigning points
to variable, but made an attempt at an awk... (4 Replies)
Discussion started by: cmccabe
4 Replies
10. Shell Programming and Scripting
I have an input file with
A=xyz
B=pqr
I would want the value in Second Field (xyz or pqr) updated with a value present in Shell Variable based on the value passed in the first field. (A or B )
while read line
do
NEW_VALUE = `some functionality done on $line`
If $line=First Field-... (1 Reply)
Discussion started by: infernalhell
1 Replies
LEARN ABOUT DEBIAN
alien::package::rpm
Alien::Package::Rpm(3pm) User Contributed Perl Documentation Alien::Package::Rpm(3pm)
NAME
Alien::Package::Rpm - an object that represents a rpm package
DESCRIPTION
This is an object class that represents a rpm package. It is derived from Alien::Package.
FIELDS
prefixes
Relocatable rpm packages have a prefixes field.
METHODS
checkfile
Detect rpm files by their extention.
install
Install a rpm. If RPMINSTALLOPT is set in the environement, the options in it are passed to rpm on its command line.
scan
Implement the scan method to read a rpm file.
unpack
Implement the unpack method to unpack a rpm file. This is a little nasty because it has to handle relocatable rpms and has to do a bit
of permissions fixing as well.
prep
Prepare for package building by generating the spec file.
cleantree
Delete the spec file.
build
Build a rpm. If RPMBUILDOPT is set in the environement, the options in it are passed to rpm on its command line.
An optional parameter, if passed, can be used to specify the program to use to build the rpm. It defaults to rpmbuild.
version
Set/get version.
When retreiving the version, remove any dashes in it.
postinst
postrm
preinst
prerm
Set/get script fields.
When retrieving a value, we have to do some truely sick mangling. Since debian/slackware scripts can be anything -- perl programs or
binary files -- and rpm is limited to only shell scripts, we need to encode the files and add a scrap of shell script to make it
unextract and run on the fly.
When setting a value, we do some mangling too. Rpm maintainer scripts are typically shell scripts, but often lack the leading shebang
line. This can confuse dpkg, so add the shebang if it looks like there is no shebang magic already in place.
Additionally, it's not uncommon for rpm maintainer scripts to contain bashisms, which can be triggered when they are ran on systems
where /bin/sh is not bash. To work around this, the shebang line of the scripts is changed to use bash.
Also, if the rpm is relocatable, the script could refer to RPM_INSTALL_PREFIX, which is set by rpm at run time. Deal with this by
adding code to the script to set RPM_INSTALL_PREFIX.
arch
Set/get arch field. When the arch field is set, some sanitizing is done first to convert it to the debian format used internally. When
it's retreived it's converted back to rpm form from the internal form.
AUTHOR
Joey Hess <joey@kitenet.net>
perl v5.14.2 2011-08-05 Alien::Package::Rpm(3pm)