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
let s:Promise = vital#fern#import('Async.Promise') | |
let s:AsyncLambda = vital#fern#import('Async.Lambda') | |
let s:root = { | |
\ 'name': 'TabPages', | |
\ 'status': 1, | |
\ '_kind': 'root', | |
\} | |
function! fern#scheme#tabpage#provider#new() abort |
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
Creating benchmark environment ... | |
Benchmarking 'ls' ... | |
0.003170 | |
Benchmarking 'find' ... | |
0.001505 | |
Benchmarking 'vim_glob' ... | |
1.894150 |
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
#!/usr/bin/env python | |
import re | |
import time | |
from typing import Iterator, Tuple, Optional | |
import requests | |
# ================================================================ | |
TOKEN = "****************************************" | |
USER = "username" |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Ansi 0 Color</key> | |
<dict> | |
<key>Color Space</key> | |
<string>sRGB</string> | |
<key>Blue Component</key> | |
<real>0.12941176470588237</real> |
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
let s:SYMBOL = '@@cancelSignal' | |
function! s:_vital_created(module) abort | |
let a:module.Symbol = s:SYMBOL | |
endfunction | |
function! s:cancelable() abort | |
let subscribers = [] | |
let signal = { | |
\ 'signaled': v:false, |
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
let s:Benchmark = vital#vital#import('Vital.Benchmark') | |
let s:Old = vital#vital#import('Data.List') | |
let s:New = vital#vital#import('Vital.List') | |
function! s:map() abort | |
let list = repeat(['hello'], 1000) | |
echo 'map()' | |
echo printf( | |
\ ' Old: %f sec', | |
\ s:Benchmark.timeit({ -> s:OldList.map(list, { v -> toupper(v) }) }) |
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
{ | |
"homepage": "https://taskfile.org", | |
"description": "A task runner / build tool that aims to be simpler and easier to use", | |
"license": "MIT", | |
"version": "v2.2.0", | |
"architecture": { | |
"64bit": { | |
"url": "https://github.com/go-task/task/releases/download/v2.2.0/task_windows_amd64.zip", | |
"hash": "1fd06172c7ee66529dd8cb1709083b863713d01317be55f978aac8039a290c8c" | |
}, |
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
let s:n = 10000 | |
let s:data = repeat(["Hello World\r"], s:n) | |
let s:expect = repeat(['Hello World'], s:n) | |
function! s:validate(data) abort | |
for i in range(len(s:expect)) | |
if a:data[i] !=# s:expect[i] | |
echoerr printf('%d: %s != %s', i, a:data[i], s:expect[i]) | |
endif | |
endfor |
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
import socket | |
import random | |
import platform | |
from dpkt.tcp import TCP, TH_SYN | |
print(platform.system()) | |
if platform.system() in ('FreeBSD', 'Darwin'): | |
# | |
# > Before FreeBSD 10.0 packets received on raw IP sockets had the ip_hl sub- |
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! s:_vital_loaded(V) abort | |
let s:Job = a:V.import('System.Job') | |
let s:Promise = a:V.import('Async.Promise') | |
endfunction | |
function! s:_vital_depends() abort | |
return ['System.Job', 'Async.Promise'] | |
endfunction | |