Sunday, August 26, 2007

string parsing using bash

Unfortunately, Google doesn't know about this.

Even Google global indexes doesn't refer to any link with regards to this entry and topic. Interesting but weird.

var1=`ifconfig eth0`
var2=${var2%% *}

The output of the above bash script when executed would be the current IP address of eth0.

String parsing can be done using special bash characters as shown with the above bash script sample. The string parsing shown above can also be done directly from terminal like so

# var1=`ifconfig eth0` ; var2=${var1#*addr:} | echo ${var2%% *}

%%, % and #* are the special bash character search commands.

Now, the next question is how fast google indexes the web? I am going to measure it by publishing this post, I know Google indexes this entry so fast which I don't know why. I need to see if Google algorith can tag these characters as a bell for search queries as well.


Before I started this blog entry. Searching Google DOES NOT give me any results from searching ANY character combinations shown below. I have searched it one line at at time and leads to ZERO result. See my search quries


Google index also suggested that I should remove quotes and results are all the same, NOT FOUND. I am posting my search screenshots below referring to NOT FOUND results by Google using the above search keyword.

So that we can conclude

a. If these characters are special for Google and removes them from any search keywords or character before searching global indexes.

b. After posting this entry, if Google global indexes can return something or refer to this blog entry right after several minutes of posting this? That basically means Google spiders knows these character keywords and therefor Google does not have it from their indexes before this blog entry was posted! Interesting.

Google not found search link 1, search 2, search 3,, search 4, yes google spiders failed to return results, perhaps its a special character for google algorithm as well. :)

I would edit this page back again IF and ONLY IF Google returns and crawls those special characters from this entry. And IF Google refers to this blog entry when somebody searches for those search key characters. :)



Sign up for PayPal and start accepting credit card payments instantly.
ILoveTux - howtos and news | About | Contact | TOS | Policy