As configured in my dotfiles.
start new:
tmux
start new with session name:
| Manual - By script | |
| In machine A, | |
| — | |
| UNIX: | |
| code --list-extensions | xargs -L 1 echo code --install-extension | |
| — | 
As configured in my dotfiles.
start new:
tmux
start new with session name:
| const interval = 1000; | |
| const acceptableDelay = 3; | |
| let lastCheck = 0; | |
| (function checkEventLoop() { | |
| const now = Date.now(); | |
| if (lastCheck) | |
| if (now - lastCheck > interval + acceptableDelay) { | |
| console.log('\x1b[31m', 'event loop delay', (now - lastCheck - interval) + 'ms', '\x1b[0m'); | 
| // Part of https://github.com/chris-rock/node-crypto-examples | |
| // Nodejs encryption of buffers | |
| var crypto = require('crypto'), | |
| algorithm = 'aes-256-ctr', | |
| password = 'd6F3Efeq'; | |
| var fs = require('fs'); | |
| var zlib = require('zlib'); | 
| #!/bin/bash | |
| # Removes old revisions of snaps | |
| # CLOSE ALL SNAPS BEFORE RUNNING THIS | |
| echo "Current usage:"; | |
| du -h /var/lib/snapd/snaps | |
| echo ""; | |
| set -eu | |
| snap list --all | awk '/disabled/{print $1, $3}' | | |
| while read snapname revision; do | 
| #!/bin/bash | |
| ### VARIABLES | |
| base_data_path="/home/docker" | |
| mongo_pass="PASSSS" | |
| ###### install resolvconf - to use shecan smart dns | 
| echo ' | |
| FROM ubuntu | |
| RUN apt update | |
| RUN apt install autossh -y | |
| RUN ssh-agent bash | |
| ENTRYPOINT ["/usr/bin/autossh", "-M", "0", "-T", "-N", "-oStrictHostKeyChecking=no", "-oServerAliveInterval=180", "-oUserKnownHostsFile=/dev/null", "-D","0.0.0.0:8888"] | |
| ' > Dockerfile ; \ | |
| project="ssh-tunnel" ; \ | |
| sudo docker rmi ${project} --force ; \ | |
| sudo docker build -t ${project} . ; \ | 
People
|   :bowtie: | 😄 :smile: | 😆 :laughing: | 
|---|---|---|
| 😊 :blush: | 😃 :smiley: | :relaxed: | 
| 😏 :smirk: | 😍 :heart_eyes: | 😘 :kissing_heart: | 
| 😚 :kissing_closed_eyes: | 😳 :flushed: | 😌 :relieved: | 
| 😆 :satisfied: | 😁 :grin: | 😉 :wink: | 
| 😜 :stuck_out_tongue_winking_eye: | 😝 :stuck_out_tongue_closed_eyes: | 😀 :grinning: | 
| 😗 :kissing: | 😙 :kissing_smiling_eyes: | 😛 :stuck_out_tongue: | 
| sudo rm /var/lib/snapd/cache/* | |
| sudo journalctl --vacuum-size=10M | |
| sudo npm cache clean --force | |
| sudo yarn cache clean | 
| const _ = require('lodash'); | |
| /** | |
| Write a function checking that the given string is valid. We consider a string to be valid if all the characters of the string have exactly the same frequency. | |
| Examples: | |
| "aabbcc" is a valid string | |
| "aabbccc" is an invalid string | |
| */ |