vagrant destroydefault: Are you sure you want to destroy the ‘default’ VM? [y/N] y==> default: Destroying VM and associated drives…There was an error while executing VBoxManage, a CLI used by Vagrantfor controlling VirtualBox. The command and stderr is shown below. Command: [“unregistervm”, “71cc684f-d03a-4369-af9c-ac199d7bf9b7”, “–delete”] Stderr: VBoxManage: error: Cannot unregister the machine ‘CnC_default_1643660523119_45689’ while it is […]
Category: Uncategorized
How to get a remote server SSL certificate
No good deed ever gets unpunished.
Whenever you feel like criticizing any one, just remember that all the people in this world haven’t had the advantages that you’ve had.
Replace all dots in filenames except the extension on Linux
for f in .; do pre=”${f%.}”; suf=”${f##.}”; mv -i -f — “$f” “${pre//./_}.${suf}”; done
Count number of directories in the current directory using Linux cli
ls -1 | wc -l
Count number of files in a directory using Linux cli
ls -l . | egrep -c ‘^-‘
How To Install PHP (7.4, 7.3 & 5.6) on Debian 9 Stretch
Prerequisites Login to your Debian 9 system using shell access. For remote systems connect with SSH. Windows users can use Putty or other alternatives applications for SSH connection. ssh root@debian9 Run below commands to upgrade the current packages to the latest version. sudo apt update sudo apt upgrade Let’s execute the following commands to install […]
Fix casks with `depends_on` that reference pre-Mavericks
If you get an error of the type Error: Cask ‘hex-fiend-beta’ definition is invalid: invalid ‘depends_on macos’ value: “:lion”, where hex-fiend-beta can be any cask name, and :lion any macOS release name, run the following command: /usr/bin/find “$(brew –prefix)/Caskroom/”*’/.metadata’ -type f -name ‘*.rb’ -print0 | /usr/bin/xargs -0 /usr/bin/perl -i -pe ‘s/depends_on macos: \[.*?\]//gsm;s/depends_on macos: .*//g’ This will remove all depends_on macos references […]
How to run VLC player as root user
Explanation: The initialization script check if the UID is equals to zero. Zero is reserved for the root user. Using sed to replace geteuid for getppid fools the initialization script because it is always > 0. While running the VLC as root is not recommended, it works. Be aware of the risks and obviously do not do it for production environments.