BASH_SRV Telegram 53
🖥 Bash скрипт проверки существования файла, каталога, пользователя


Проверка существования файла:


?
if ! [ -f /path/to/file ]; then
echo 'No file'
fi


Проверка существования директории:


if ! [ -d /path/directory/ ]; then
echo 'No directory'
fi


Проверка существования пользователя:


grep "username:" /etc/passwd >/dev/null
if [ $? -ne 0 ]; then
echo 'No username found'
fi


👉@bash_srv
Please open Telegram to view this post
VIEW IN TELEGRAM
👍10



tgoop.com/bash_srv/53
Create:
Last Update:

🖥 Bash скрипт проверки существования файла, каталога, пользователя


Проверка существования файла:


?
if ! [ -f /path/to/file ]; then
echo 'No file'
fi


Проверка существования директории:


if ! [ -d /path/directory/ ]; then
echo 'No directory'
fi


Проверка существования пользователя:


grep "username:" /etc/passwd >/dev/null
if [ $? -ne 0 ]; then
echo 'No username found'
fi


👉@bash_srv

BY Bash Советы




Share with your friend now:
tgoop.com/bash_srv/53

View MORE
Open in Telegram


Telegram News

Date: |

How to build a private or public channel on Telegram? Commenting about the court's concerns about the spread of false information related to the elections, Minister Fachin noted Brazil is "facing circumstances that could put Brazil's democracy at risk." During the meeting, the information technology secretary at the TSE, Julio Valente, put forward a list of requests the court believes will disinformation. The visual aspect of channels is very critical. In fact, design is the first thing that a potential subscriber pays attention to, even though unconsciously. For crypto enthusiasts, there was the “gm” app, a self-described “meme app” which only allowed users to greet each other with “gm,” or “good morning,” a common acronym thrown around on Crypto Twitter and Discord. But the gm app was shut down back in September after a hacker reportedly gained access to user data. There have been several contributions to the group with members posting voice notes of screaming, yelling, groaning, and wailing in different rhythms and pitches. Calling out the “degenerate” community or the crypto obsessives that engage in high-risk trading, Co-founder of NFT renting protocol Rentable World emiliano.eth shared this group on his Twitter. He wrote: “hey degen, are you stressed? Just let it out all out. Voice only tg channel for screaming”.
from us


Telegram Bash Советы
FROM American