This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Using base64_encode as en example | |
function email_obf_html(string $email): string | |
{ | |
return sprintf('<span data-obf-email="%s">...</span>', base64_encode($email)); | |
} | |
function email_obf_mailto_attr(string $email): string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get great explanations for any commands here | |
# https://explainshell.com/ | |
### Renaming branches | |
# Rename local branch | |
# To rename current branch | |
git branch -m new-name | |
# To rename another branch | |
git branch -m old-name new-name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Show running (potentially stuck) sql processes | |
show processlist; | |
-- Switch to some table | |
use tablename; | |
-- Show stuff | |
show tables; | |
show databases; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get great explanations for any commands here | |
# https://explainshell.com/ | |
# Register your ssh key on remote server | |
# Command should be run on your machine | |
# more https://www.ssh.com/ssh/copy-id | |
ssh-copy-id -i ~/.ssh/{mykey} remoteuser@{remoteHostOrIP} | |
# for generic key | |
ssh-copy-id remoteuser@{remoteHostOrIP} | |
# then login only using passphrase |