Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 129846

Summary: Small mistake in "Bash by example, Part 2" document
Product: [OLD] Docs on www.gentoo.org Reporter: Pablo Antonio <pabloa>
Component: Other documentsAssignee: Xavier Neys (RETIRED) <neysx>
Status: RESOLVED FIXED    
Severity: normal CC: docs-team, drobbins
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: All   
URL: http://www.gentoo.org/doc/en/articles/bash-by-example-p2.xml
Whiteboard:
Package list:
Runtime testing required: ---

Description Pablo Antonio 2006-04-13 11:26:45 UTC
There's a small mistake in one of the explanations of a specific example; more precisely, it says:
In the code, "$x" is the name of a file, and "${x##.*}" has the effect of stripping all text except that following the last period in the filename.

Where it should say:
In the code, "$x" is the name of a file, and "${x##*.}" has the effect of stripping all text except that following the last period in the filename.

(Notice that the only change is the wildcard in "${x##.*}". The script itself does not require any corrections.)
Comment 1 Pablo Antonio 2006-04-13 11:37:17 UTC
Actually, I realized the same mistake occurs two more times in the same paragraph. It's not that it's a vital error, but it surely creates some surprise in newbies' minds.
Comment 2 Xavier Neys (RETIRED) gentoo-dev 2006-04-25 05:58:30 UTC
Fixed. Thanks for reporting.