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
# Creates 993 nc processes. Returns in about 1 minute max | |
ip=127.0.0.1 | |
b(){ for i in {0..992};do nc $ip -w1 -vz $((i*66+1))-$((i*66+66>65535?65535:i*66+66)) 2>&1|egrep 'open|succeed'&done;wait;} 2>/dev/null;b |
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
@font-face { | |
font-family: 'Material Icons'; | |
font-style: normal; | |
font-weight: 400; | |
src: url(https://fonts.gstatic.com/s/materialicons/v140/flUhRq6tzZclQEJ-Vdg-IuiaDsNcIhQ8tQ.woff2) format('woff2'); | |
} | |
.material-icons { | |
font-family: 'Material Icons'; | |
font-weight: normal; |
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
{ | |
"name": "Ref", | |
"timestamp": "2022-10-19T11:12:47.433Z", | |
"version": { | |
"major": 1, | |
"minor": 0, | |
"patch": 0 | |
}, | |
"tags": {}, | |
"tokens": [ |
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
# Optionally delete the existing cluster first if you have it | |
# k3d d | |
# Work around "pods being evicted" issue | |
# https://github.com/rancher/k3d/issues/133 | |
k3d c \ | |
--server-arg '--kubelet-arg=eviction-hard=imagefs.available<1%,nodefs.available<1%' \ | |
--server-arg '--kubelet-arg=eviction-minimum-reclaim=imagefs.available=1%,nodefs.available=1%' | |
# Wait until the base system nodes are running |
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
:root { | |
--side-bar-bg-color: #fafafa; | |
--control-text-color: #777; | |
} | |
@include-when-export url(https://fonts.loli.net/css?family=Open+Sans:400italic,700italic,700,400&subset=latin,latin-ext); | |
@font-face { | |
font-family: 'Open Sans'; | |
font-style: normal; |
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
call rpcnotify(1, 'Gui', 'Font', 'Fira Code 22') | |
let s:fontsize = 22 | |
function! AdjustFontSize(amount) | |
let s:fontsize = s:fontsize+a:amount | |
call rpcnotify(1, 'Gui', 'Font', 'Fira Code ' . s:fontsize) | |
endfunction | |
noremap <c-+> :call AdjustFontSize(1)<CR> | |
noremap <c--> :call AdjustFontSize(-1)<CR> |
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
version: '3' | |
services: | |
app: | |
image: nginx:alpine | |
ports: ["80:80"] | |
restart: unless-stopped | |
restarter: | |
image: docker:cli | |
volumes: ["/var/run/docker.sock:/var/run/docker.sock"] |
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
function! ale_linters#gitcommit#commitlint#Handle(buffer, lines) abort | |
" Matches patterns line the following: | |
let l:pattern = '^\(✖\|⚠\)\s\+\(.*\) \(\[.*\]\)$' | |
let l:output = [] | |
let l:line = getline(1) | |
if l:line[0] != '#' | |
for l:match in ale#util#GetMatches(a:lines, l:pattern) | |
let l:item = { | |
\ 'lnum': 1, |
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
$ori = @{} | |
Try { | |
$i = 0 | |
# Loading .env files | |
if(Test-Path $args[0]) { | |
foreach($line in (Get-Content $args[0])) { | |
if($line -Match '^\s*$' -Or $line -Match '^#') { | |
continue | |
} |
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
// Wait until innerheight changes, for max 120 frames | |
function orientationChanged() { | |
const timeout = 120; | |
return new window.Promise(function(resolve) { | |
const go = (i, height0) => { | |
window.innerHeight != height0 || i >= timeout ? | |
resolve() : | |
window.requestAnimationFrame(() => go(i + 1, height0)); | |
}; | |
go(0, window.innerHeight); |
NewerOlder