Create ini file using tee instead of touch

This commit is contained in:
Shivam Mathur 2020-05-22 15:46:30 +05:30
parent 4fb049a68b
commit 190220c10d
No known key found for this signature in database
GPG Key ID: 3E13E4C8591ACC2A

View File

@ -403,6 +403,6 @@ ext_dir=$(php -i | grep "extension_dir => /" | sed -e "s|.*=> s*||")
scan_dir=$(php --ini | grep additional | sed -e "s|.*: s*||")
ini_file=$(php --ini | grep "Loaded Configuration" | sed -e "s|.*:s*||" | sed "s/ //g")
pecl_file="$scan_dir"/99-pecl.ini
sudo touch "$pecl_file" >/dev/null 2>&1
echo '' | sudo tee "$pecl_file"
sudo chmod 777 "$ini_file" "$pecl_file" "$tool_path_dir"
add_log "$tick" "PHP" "$status PHP $semver"