- C-a == Ctrl-a
- M-a == Alt-a
:q close
:w write/saves
:wa[!] write/save all windows [force]
:wq write/save and close
node_modules |
FROM node:8.9.3 as tools | |
COPY package.json ./ | |
RUN npm install --non-interactive --production=false |
sudo mkdir -pv /build/toolchain/mac32/openssl-1.0.1p/lib/ | |
cd /build/toolchain/mac32/openssl-1.0.1p/lib/ | |
sudo ln -s /Applications/VMware\ Client\ Integration\ Plug-in.app/Contents/Library/lib/libssl.1.0.1.dylib | |
sudo ln -s /Applications/VMware\ Client\ Integration\ Plug-in.app/Contents/Library/lib/libcrypto.1.0.1.dylib | |
sudo /Applications/VMware\ Client\ Integration\ Plug-in.app/Contents/Library/vmware-csd-installer --install |
CODEMOD_PATH="/tmp/js-codemod" | |
npm i -g eslint jscodeshift | |
git clone https://github.com/cpojer/js-codemod.git | |
# Run eslint fix | |
npm run cli eslint --fix "$1" | |
# Run es6 codemod | |
for codemod in no-vars template-literals object-shorthand unchain-variables unquote-properties updated-computed-props; |
- name: install ssh keys | |
copy: | |
content: "{{ item.value }}" | |
dest: /home/www/.ssh/{{ item.key }} | |
mode: 0600 | |
owner: www | |
with_dict: github_ssh_keys | |
no_log: True | |
- name: install ssh key |
# cpu | |
time echo "scale=5000; a(1)*4" | bc -l | |
# disk | |
time sh -c "dd if=/dev/zero of=/tmp/test.tmp bs=4k count=200000 && sync" | |
# io | |
mysqlslap --user=root --password --concurrency=50 --iterations=10 --number-int-cols=5 --number-char-cols=20 --auto-generate-sql --verbose | |
# à tester |
# Catalina | |
sudo /Applications/Install\ macOS\ Catalina.app/Contents/Resources/createinstallmedia \ ~/Code | |
--volume /Volumes/Install\ macOS\ Mojave \ | |
--nointeraction | |
# Mojave | |
sudo /Applications/Install\ macOS\ Mojave.app/Contents/Resources/createinstallmedia \ ~/Code | |
--volume /Volumes/Install\ macOS\ Sierra \ | |
--nointeraction |
#!/usr/bin/expect | |
spawn mysql -u root -p | |
expect "assword:" | |
send "<pass>\r" | |
interact |
#!/bin/bash | |
BACKUP=/home/backups/redis | |
REDIS_SOURCE=/var/lib/redis/dump.rdb | |
REDIS_DEST=$BACKUP/$(date +"%Y-%m-%d")-dump.rdb | |
find $BACKUP/* -name "*.rdb" -mtime +7 -exec rm {} \; | |
redis-cli save > /dev/null | |
cp $REDIS_SOURCE $REDIS_DEST |