11-08-2011
If you're not willing to use config files, you should enforce the same configuration on all three servers so your scripts don't have to change. Install symlinks if necessary.
Until you do, something, somewhere, will always have to know all the per-server settings for each server.
Quote:
The email thing - that's a safety feature.
But why's it handled in your script and not on the server? Have the default sendmail address or somesuch end up in a mailing list on your dev server, or the other proper destination in production, instead of hardcoding different behavior in your script.
Quote:
Your first suggestion - sanity checks on directory names. If the directories are identical between QA and PROD, then directory checks to determine differences in the regions would not be able to tell the difference.
That's not what they're for, and checking like you suggest isn't something your script ought to be doing.
Either use config files, or enforce the same configuration everywhere, don't build an unmaintainable rube-goldberg machine.
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
how can i determine that
what percentage of stack region is currently is used?
(i am using tru64 unix) (2 Replies)
Discussion started by: yakari
2 Replies
2. Solaris
Hello experts,
I am using Veritas Volume Manager 5.0. How can i take private region backup and restoration.
thanks in advance... (3 Replies)
Discussion started by: younus_syed
3 Replies
3. Shell Programming and Scripting
Hi:
Let's suppose I want to replace all the | by > ONLY when | is between . Usually (and it works) I would do something like
sed -e 's/\(\*\)|\(*\]\)/\1>\2/g'
where I have to "save" some portions of the matched region and use them with the \n metacharacter. I was wondering if I could... (2 Replies)
Discussion started by: islegmar
2 Replies
4. Programming
Hi guys,
I hope everybody is doing fine. I have written this small program which solves the critical region problem. Only on of the two threads can make changes to a common variable called counter. I am using two semaphores, is it possible to write the same program using only one semaphore? Here... (0 Replies)
Discussion started by: gabam
0 Replies
5. Shell Programming and Scripting
How can I find the regions between specific lines?
I have a file which contains lines like this:
chr1 0 17388 0
chr1 17388 17444 1
chr1 17444 17599 2
chr1 17599 17601 1
chr1 17601 569791 0
chr1 569791 569795 1
chr1 569795 569808 2
chr1 569808 569890 3
chr1 569890 570047 4 ... (9 Replies)
Discussion started by: linseyr
9 Replies
6. AIX
Dears my rootvg is missed up i can not extend the /opt
as soon as i try to extend the Filesystem its give me that there is not enough space .
as there any way to change the REGION of the LVs in HDISK1 ?
lspv -p hdisk0
hdisk0:
PP RANGE STATE REGION LV NAME TYPE ... (8 Replies)
Discussion started by: thecobra151
8 Replies
7. Shell Programming and Scripting
Input file
2 5 ASFGEWTEWRQWEQ
10 20 QEWIORUEIOUEWORUQWEQWRQRQWGQWGFQ
1 6 WRQTQWTQTQWTQT
Desired output file
2 5 ASFGEWTEWRQWEQ
10 20 QEWIORUEIOUEWORUQWEQWRQRQWGQWGFQ
1 6 WRQTQWTQTQWTQT
Column 1 is the start region of underline the text in column 3;
Column 2 is the end region of... (13 Replies)
Discussion started by: cpp_beginner
13 Replies
8. Shell Programming and Scripting
portsuf=25
port=20925
I need to replace 09 with 25
It should be like 22525.
Can some please help with command or script. (4 Replies)
Discussion started by: bhas85
4 Replies
9. Programming
Hello, I am trying to concatenate two strings by merging the overlapped region. E.g.
Seq1=ACGTGCCC
Seq2=CCCCCGTGTGTGT
Seq_merged=ACGTGCCCCCGTGTGTGTFunction strcat(char *dest, char *src) appends the src string to the dest string, ignoring the overlapped parts (prefix of src and suffix of dest).... (30 Replies)
Discussion started by: yifangt
30 Replies
10. UNIX for Dummies Questions & Answers
Hi,
I would like to know how can I get a mean score value by ID over a defined genomic region. Here it is an example:
file1
12 100 103 id1
12 110 112 id1
12 200 203 id2
file2
12 100 101 1
12 101 102 0.8
12 102 103 0.7
12 110 111 2.5
12 111 112 2.8
12 200 201 10.1
12 201 202... (7 Replies)
Discussion started by: fadista
7 Replies
LEARN ABOUT SUSE
xequalregion
XEmptyRegion(3) XLIB FUNCTIONS XEmptyRegion(3)
NAME
XEmptyRegion, XEqualRegion, XPointInRegion, XRectInRegion - determine if regions are empty or equal
SYNTAX
Bool XEmptyRegion(Region r);
Bool XEqualRegion(Region r1, Region r2);
Bool XPointInRegion(Region r, int x, int y);
int XRectInRegion(Region r, int x, int y, unsigned int width, unsigned int height);
ARGUMENTS
r Specifies the region.
r1
r2 Specify the two regions.
width
height Specify the width and height, which define the rectangle.
x
y Specify the x and y coordinates, which define the point or the coordinates of the upper-left corner of the rectangle.
DESCRIPTION
The XEmptyRegion function returns True if the region is empty.
The XEqualRegion function returns True if the two regions have the same offset, size, and shape.
The XPointInRegion function returns True if the point (x, y) is contained in the region r.
The XRectInRegion function returns RectangleIn if the rectangle is entirely in the specified region, RectangleOut if the rectangle is
entirely out of the specified region, and RectanglePart if the rectangle is partially in the specified region.
SEE ALSO
XCreateRegion(3), XIntersectRegion(3)
Xlib - C Language X Interface
X Version 11 libX11 1.3.2 XEmptyRegion(3)