Search Results

Search: Posts Made By: drl
Forum: What is on Your Mind? 4 Days Ago
368
Posted By Neo
Moderators of the Year 2019 - Ravinder Singh and Victor Berridge
Today, I am very pleased to announce that the Moderator of the Year Award, 2019 has two very deserving winners.

Ravinder Singh (RavinderSingh13) and Victor Berridge (vbe)

Victor (vbe) has...
143
Posted By RudiC
Looks like the well known / infamous DOS line...
Looks like the well known / infamous DOS line terminator problem:


$ RPT=test
$ sed 'p' $RPT
sed: can't read test: No such file or directory
$ RPT=test$'\r'
$ sed 'p' $RPT
: No such file or...
241
Posted By nezabudka
It should work the same way on both the "bash"...
It should work the same way on both the "bash" and the "ksh93"
cat file
tom is hot
one two three
four five six
set -A store
#declare -A store
eval "store=($(awk '{for(i=1;i<=NF;i++) print "["...
711
Posted By RavinderSingh13
Hello abhaydas, Always try to following rule...
Hello abhaydas,

Always try to following rule of 1 thread ==> 1 question please.

Geeks have really helped you in this thread, so for future users who want to get reference from this thread, will...
Forum: Shell Programming and Scripting 2 Weeks Ago
500
Posted By MadeInGermany
Can be done as a { } group. (Note: there must be...
Can be done as a { } group. (Note: there must be a semicolon or newline before the closing brace! And of cause spaces next to the [ ] { } )
if [ -f ./file2 ] && [ -f ./file3 ] && { [ -f ./file1 ]...
130
Posted By Aia
Hello sravani25, If you were to post the...
Hello sravani25,

If you were to post the output of your df -h command it could make it possible to let you know even more.
It is OK for learning and quick iteration what you have done with...
960
Posted By MadeInGermany
They mean: copying a file, especially a big file,...
They mean: copying a file, especially a big file, is done in steps. If there is a power loss in between, the status of the file is unknown: can be empty or partially copied.
In contrast,...
960
Posted By joeyg
Seems illogical to me. When working on...
Seems illogical to me.

When working on complex programming, I often take the backup even more seriously. I sequentially number versions to help me go back and find prior logic.
cp GreatScript...
877
Posted By rbatte1
I must admit, I like jim mcnamara's neat...
I must admit, I like jim mcnamara's neat response. It made me wonder about the string often all of the kinds of Norway as an example where the string might exist embedded in another word. Is this a...
877
Posted By jim mcnamara
Suppose you wanted to count the number of times...
Suppose you wanted to count the number of times the word of occurs in a file


Owner@Owner-PC ~
$ cat filename
all of the kings of Norway

Owner@Owner-PC ~
$ grep -Fo 'of' filename |wc -l
2
Forum: Shell Programming and Scripting 4 Weeks Ago
246
Posted By nezabudka
Hi my five cents sed 's/.*=//' myFile ...
Hi

my five cents
sed 's/.*=//' myFile
and light artillery
grep -o '[^=]*$' myFile
954
Posted By MadeInGermany
[Tip] A better echo
Often it has been said that echo is neither portable nor correct.
Here is an input.txt:

line1
line2
-n
line4
-en
line6
-x
line8
Then the following fails with BSD/Linux/bash:

while IFS=...
1,257
Posted By jim mcnamara
This standard library call: nftw (or ftw) IBM...
This standard library call: nftw (or ftw)
IBM Knowledge Center (https://www.ibm.com/support/knowledgecenter/SSLTBW_2.2.0/com.ibm.zos.v2r2.bpxbd00/rnftw.htm)

supports the find command traversing...
920
Posted By RudiC
With grep and friends you'll get one count per...
With grep and friends you'll get one count per run, so you'll have to go through the file twice. Might not be a problem with small files, but resource consumption increases with sizes. Taylor your...
920
Posted By RavinderSingh13
Hello mcesmcsc, Good that you have shown us...
Hello mcesmcsc,

Good that you have shown us what you have tried to solve your own problem, keep it up.
Could you please do let us know sample of Input_file and expected output in CODE TAGS too it...
1,088
Posted By RavinderSingh13
Hello Sennenmut, Good that you were able to...
Hello Sennenmut,

Good that you were able to solve the problem by your own. But after working on few posts in this thread and suddenly declaring that you have solved the problem will not help...
906
Posted By RudiC
Here you are: awk ' !(a[$1]) {a[$1]=$0...
Here you are:
awk '
!(a[$1]) {a[$1]=$0 # if array element indexed by $1 is unset or 0, set it to
# the line (i.e....
Forum: What is on Your Mind? 11-22-2019
2,510
Posted By Neo
I just completed (for the most part) a database...
I just completed (for the most part) a database optimization which was slowing the site down.

In a nutshell, when I created some new code to mitigate against Google soft 404 "errors" (slim...
1,973
Posted By Neo
pythonic is more about style and opinion than...
pythonic is more about style and opinion than anything useful for producing a result.

Some sites like stack* in fact, close these kinds of threads and place them in the category of "primarily...
963
Posted By MadeInGermany
ls | sed -n 's/^status_\(.*\)[.]log$/\1/p'
ls | sed -n 's/^status_\(.*\)[.]log$/\1/p'
2,349
Posted By RudiC
Do the two file versions coexist, or is there one...
Do the two file versions coexist, or is there one single file max?
And, why a one liner? What be the benefit thereof?
Forum: What is on Your Mind? 11-15-2019
2,510
Posted By Neo
Daily backups: Before moving man pages to...
Daily backups:

Before moving man pages to new database:

-rw-r--r-- 1 root root 1292500820 Nov 13 22:31 main_masterdump_2019-11-13-22.sql.gz

After moving man pages to new database:
...
892
Posted By Peasant
After 1300ish posts one should know to post error...
After 1300ish posts one should know to post error you found.
This will benefit others and be in search results.

So, please, post the solution.

Regards
Peasant.
974
Posted By vbe
In other words when you type which salt at your...
In other words when you type which salt at your prompt it should return you the path... what is it?

Then if salt works in interactive at your prompt, and you see no path, it might be salt as a...
790
Posted By Peasant
Why not check it by creating some files and doing...
Why not check it by creating some files and doing for loop with a simple echo ?
Default order of things should be apparent from the output produced.

As for other requirements, it will have to be...
Showing results 1 to 25 of 381

 

Featured Tech Videos

All times are GMT -4. The time now is 09:56 AM.
Unix & Linux Forums Content Copyright 1993-2020. All Rights Reserved.
Privacy Policy