...
 
Commits (2)
......@@ -106,16 +106,16 @@ Table of Contents
### 9 [Trap](./09-trap/)
* 9.1 [EXIT](./09-trap/1-exit.sh)
Setting up an exit event handler.
* 9.1 [SIGUSR1](./09-trap/2-usr1.sh)
* 9.2 [SIGUSR1](./09-trap/2-usr1.sh)
Setting up a UNIX signal handler.
* 9.3 [Exercises](./09-trap/3-exercises.md)
### 0 [Completion](./10-completion/)
* 0.1 [Wordlist](./10-completion/1-wordlist.sh)
### 10 [Completion](./10-completion/)
* 10.1 [Wordlist](./10-completion/1-wordlist.sh)
Bash-completion provided as static list of words.
* 0.2 [Function](./10-completion/2-function.sh)
* 10.2 [Function](./10-completion/2-function.sh)
Bash-completion dynamically provided by a function.
* 0.3 [Exercise](./10-completion/3-exercise.md)
* 10.3 [Exercise](./10-completion/3-exercise.md)
Author and Contact
------------------
......
......@@ -11,7 +11,7 @@ file2summary() {
# @param string File or directory name.
file2nr() {
basename "$1" | perl -pne '
s/.*([0-9]+).*/$1/
s/(0*)?([1-9][0-9]*).*/$2/
'
}
......