- save agnoster-light.zsh-theme to
~/.oh-my-zsh/themes/. - edit
ZSH_THEMEin~/.zshrctoagnoster-light - change the color theme of terminal to
solarized-light - open a new terminal
This file contains hidden or 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
| ANT000000 | Antiques & Collectibles / General | |
|---|---|---|
| ANT001000 | Antiques & Collectibles / Americana | |
| ANT002000 | Antiques & Collectibles / Art | |
| ANT003000 | Antiques & Collectibles / Autographs | |
| ANT005000 | Antiques & Collectibles / Books | |
| ANT006000 | Antiques & Collectibles / Bottles | |
| ANT007000 | Antiques & Collectibles / Buttons & Pins | |
| ANT008000 | Antiques & Collectibles / Care & Restoration | |
| ANT009000 | Antiques & Collectibles / Transportation | |
| ANT010000 | Antiques & Collectibles / Clocks & Watches |
This file contains hidden or 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
| #!/usr/bin/env bash | |
| # see https://carstenwindler.de/php/enable-xdebug-on-demand-in-your-local-docker-environment/ | |
| if [ "$#" -ne 1 ]; then | |
| SCRIPT_PATH=`basename "$0"` | |
| echo "Usage: $SCRIPT_PATH enable|disable" | |
| exit 1; | |
| fi | |
| # Expects service to be called app in docker-compose.yml |
60 Seconds backwards timer with counter
i=60;while [ $((i--)) -gt 0 ]; do printf "\r%02d" $i;sleep 1;done;echo
300 Seconds countdown with spinner
i=300;while [ $((i--)) -gt 0 ]; do for s in / - \\ \|; do printf "\r%03d %s" $i $s;sleep .25;done;done;echo
Import .env file into current shell
No, seriously, don't. You're probably reading this because you've asked what VPN service to use, and this is the answer.
Note: The content in this post does not apply to using VPN for their intended purpose; that is, as a virtual private (internal) network. It only applies to using it as a glorified proxy, which is what every third-party "VPN provider" does.
- A Russian translation of this article can be found here, contributed by Timur Demin.
- A Turkish translation can be found here, contributed by agyild.
- There's also this article about VPN services, which is honestly better written (and has more cat pictures!) than my article.
This file contains hidden or 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 | |
| $digits = 6; | |
| $interval = 30; | |
| $secret = 'secret_key'; | |
| $prevTotp = ''; | |
| for ($i = 0; $i < $interval * 4; $i++) { | |
| $time = time(); | |
| $counter = (string) floor($time / $interval); | |
| $hmac = hash_hmac('sha1', $counter, $secret); |
This file contains hidden or 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 | |
| $header = '{"alg":"HS256","typ":"JWT"}'; | |
| $payload = '{"sub":"1234567890","name":"John Doe","role":"user"}'; | |
| $encodedHeader = base64url_encode($header); | |
| $encodedPayload = base64url_encode($payload); | |
| $signature = hash_hmac('sha256', "{$encodedHeader}.{$encodedPayload}", 'secret', true); | |
| $signedSignature = base64url_encode($signature); | |
| $jwt = join('.', [$encodedHeader, $encodedPayload, $signedSignature]); |
This file contains hidden or 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
| float decel(float x) { // as an easing function | |
| return 1-(x-1)*(x-1); | |
| } | |
| void setup() { | |
| background(255); | |
| size(750,750,P2D); | |
| PImage img = loadImage("image.png"); | |
| strokeWeight(2); | |
| noFill(); |
This file contains hidden or 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 | |
| /** | |
| * Matt: core | |
| * Trixor: object handling | |
| * lech: Windows suppport | |
| * simivar: null support | |
| * | |
| * @see http://php.net/manual/en/function.print-r.php | |
| **/ | |
| function print_r_reverse($input) { |
NewerOlder