Friday, December 30, 2022

Bash check if file exists

FILE=/etc/resolv.conf

if test -f "$FILE"; then

    echo "$FILE exists."

fi

references

https://linuxize.com/post/bash-check-if-file-exists/

No comments:

Post a Comment