Example code correction thans to Raven Ramirez
This commit is contained in:
parent
d484e4e2ff
commit
d73dd9d0fa
1 changed files with 2 additions and 2 deletions
|
@ -49,7 +49,8 @@ debug() {
|
||||||
error() {
|
error() {
|
||||||
local message="$*"
|
local message="$*"
|
||||||
[ -z "$message" ] && return
|
[ -z "$message" ] && return
|
||||||
>&2 msg "ERROR: $message" }
|
>&2 msg "ERROR: $message"
|
||||||
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
Vous remarquez que les fonctions `error` et `debug` utilisent la fonction
|
Vous remarquez que les fonctions `error` et `debug` utilisent la fonction
|
||||||
|
@ -350,7 +351,6 @@ Pour tester notre nouvelle fonction, rajoutons le code suivant dans le fichier
|
||||||
`include.sh`:
|
`include.sh`:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|
||||||
check_file() {
|
check_file() {
|
||||||
if [ ! -f "monfichier.txt" ]
|
if [ ! -f "monfichier.txt" ]
|
||||||
then
|
then
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue