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
use swc_core::common::{FileName, SourceMap}; | |
use swc_core::common::input::StringInput; | |
use swc_core::common::sync::Lrc; | |
use swc_core::css::parser::{parser, lexer}; | |
fn main() { | |
let cm = Lrc::<SourceMap>::default(); | |
let fm = cm.new_source_file( | |
FileName::Custom("test.css".into()), |
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
function fn_r { | |
# $# 命令参数个数, $* 参数列表 | |
if [ $# -eq 0 ]; then | |
SCRIPT=$(jq -r '.scripts | keys[]' package.json | \ | |
fzf --preview-window=down:10%:wrap \ | |
--no-mouse \ | |
--preview 'jq -r --arg script {} ".scripts[\$script]" package.json') | |
if [ -n "$SCRIPT" ]; then | |
history -s "r $SCRIPT" | |
if command -v atuin >/dev/null 2>&1; then |
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
| Name | Base (nativeFS) | Current | Change | | |
| -------------------------------------------------------------------- | --------------- | --------------- | -------- | | |
| 10000_big_production-mode_disable-minimize + exec | 20.6 s ± 8.13 s | 21.1 s ± 7.65 s | +2.49 % | | |
| 10000_development-mode + exec | 1.1 s ± 11 ms | 1.55 s ± 51 ms | +41.91 % | | |
| 10000_development-mode_hmr + exec | 661 ms ± 3.7 ms | 659 ms ± 12 ms | -0.29 % | | |
| 10000_production-mode + exec | 1.76 s ± 24 ms | 2.24 s ± 36 ms | +27.51 % | | |
| arco-pro_development-mode + exec | 1.3 s ± 51 ms | 1.74 s ± 66 ms | +33.88 % | | |
| arco-pro_development-mode_hmr + exec | 376 ms ± 1.3 ms | 384 ms ± 2 ms | +2.20 % | | |
| arco-pro_production-mode + exec |
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
import { JavaScriptTracer } from "./trace"; | |
import { randomUUID } from "crypto"; | |
function withTracer<A extends any[], P>( | |
eventName: string, | |
fn: (...args: A) => Promise<P> | |
) { | |
return (...args: A) => { | |
let g = randomUUID(); |
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 python3 | |
import subprocess | |
import json | |
import sys | |
import os | |
from collections import defaultdict | |
def run_cmd(cmd, capture=True): | |
result = subprocess.run(cmd, shell=True, capture_output=capture, text=True) | |
if result.returncode != 0: |
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 python3 | |
import subprocess | |
import json | |
import os | |
def run(cmd): | |
return subprocess.check_output(cmd, shell=True, text=True).strip() | |
def main(): | |
branch = run("git rev-parse --abbrev-ref HEAD") |
OlderNewer