Beautify XML from the curl out
curl --location --request GET 'localhost:8080/health/check' | xmllint --format -
Beautify Json from the
curl --location --request GET 'localhost:8080/health/check' | python -m json.tool
Find the PID of the running port & kill the process by PID
sudo lsof -i tcp:8080
kill -9 <PID>
switch shell
chsh -s /usr/local/bin/fish
or
chsh -s `which fish`
Add alias by cat
echo "alias projects='cd $PWD'" | cat >> ~/.bash_profile
remove files
find . -type f -mtime +30 -name '*' -execdir rm -- '{}' \;
Java insalled directory in MAC
/usr/local/opt/java/libexec/openjdk.jdk/Contents/Home/lib
get authorization
curl -v --user YYYY:XXXX https://engci-maven-master.cisco.com/artifactory/webex-cca-group 2>&1 | grep Authorization