Skip to content

Instantly share code, notes, and snippets.

sudo apt install whois
mkpasswd -m sha-256 -S "04943682558b4ba7" -R 100000
@chaconcarlos
chaconcarlos / set-grub-windows.batch
Created July 4, 2020 21:05
When upgraging Windows, it's possible that for the installation process, it will replace Grub as the boot manager. This snippet gets Grub again as boot manager. - This should be executed as administrator on Windows's Powershell. - `bcdedit /enum fi
bcdedit /set "{bootmgr}" path \EFI\ubuntu\grubx64.efi
@chaconcarlos
chaconcarlos / git-import-to-repo.bash
Last active April 30, 2020 22:06
Script to import a subdirectory from a git repository to another git repository.
#!/bin/bash
#Script based on http://gbayer.com/development/moving-files-from-one-git-repository-to-another-preserving-history/
function show_help
{
echo "Usage: git-import-to-repo SOURCE_REPO_PATH IMPORT_PATH DESTINY_REPO_URL"
}
echo "git-import-to-repo script v0.1"