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 http from 'k6/http'; | |
import { sleep } from 'k6'; | |
export const options = { | |
// A number specifying the number of VUs to run concurrently. | |
vus: 6, | |
// A string specifying the total duration of the test run. | |
duration: '10s', | |
summaryTrendStats: ['avg','min','med','max','p(90)','p(95)','p(99)','p(99.9)','p(99.99)'], |
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
(defun +my/better-font() | |
(interactive) | |
;; english font | |
(if (display-graphic-p) | |
(progn | |
(set-face-attribute 'default nil :font (format "%s:pixelsize=%d" "Fira Code" 17)) ;; 11 13 17 19 23 | |
;; chinese font | |
(dolist (charset '(kana han symbol cjk-misc bopomofo)) | |
(set-fontset-font (frame-parameter nil 'font) | |
charset |
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 bash | |
SQUIRREL_DIR=$(PWD)/squirrel | |
LIBRIME_DIR=${SQUIRREL_DIR}/librime | |
if [ ! -d ${SQUIRREL_DIR} ]; then | |
git clone --recursive https://github.com/rime/squirrel.git ${SQUIRREL_DIR} | |
else | |
git -C ${SQUIRREL_DIR} pull origin master |
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
author: "lamb" | |
name: "lamb" | |
back_color: 0xffffff # 候选条背景色,24位色值,16进制,BGR顺序 | |
border_color: 0xffffff # 边框色 | |
text_color: 0x333333 # 拼音行文字颜色 | |
hilited_back_color: 0xD75A00 # 第一候选项背景背景色 | |
hilited_candidate_text_color: 0xFFFFFF # 第一候选项文字颜色 | |
hilited_candidate_label_color: 0xFFFFFF # 第一候选项编号颜色 | |
hilited_comment_text_color: 0xD05B21 # 注解文字高亮 | |
hilited_text_color: 0xffffff # 高亮拼音 (需要开启内嵌编码) |
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 | |
"""Simple HTTP Server With Upload. | |
This module builds on BaseHTTPServer by implementing the standard GET | |
and HEAD requests in a fairly straightforward manner. | |
""" | |
__version__ = "0.1" | |
__all__ = ["SimpleHTTPRequestHandler"] |
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
# migrating from https://github.com/robbyrussell/oh-my-zsh/blob/master/plugins/git/git.plugin.zsh | |
# Aliases | |
alias g='git' | |
#compdef g=git | |
alias gst='git status' | |
#compdef _git gst=git-status | |
alias gd='git diff' | |
#compdef _git gd=git-diff | |
alias gdc='git diff --cached' |
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
package fun.happyhacker; | |
import lombok.Data; | |
import org.apache.commons.codec.digest.DigestUtils; | |
import java.util.*; | |
import java.util.concurrent.TimeUnit; | |
/** | |
* @author Frost Wong <[email protected]> |
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"?> | |
<Configuration status="WARN"> | |
<Appenders> | |
<Console name="Console" target="SYSTEM_OUT"> | |
<PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n"/> | |
</Console> | |
</Appenders> | |
<Loggers> | |
<Root level="debug"> | |
<AppenderRef ref="Console"/> |
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
{ | |
"title": "Left ctrl + hjkf to Arrow Keys Vim", | |
"rules": [ | |
{ | |
"description": "Left ctrl + hjkf to arrow keys Vim", | |
"manipulators": [ | |
{ | |
"from": { | |
"key_code": "h", | |
"modifiers": { |
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
package fun.happyhacker; | |
import org.apache.log4j.FileAppender; | |
import org.apache.log4j.Layout; | |
import org.apache.log4j.helpers.LogLog; | |
import org.apache.log4j.spi.LoggingEvent; | |
import java.io.File; | |
import java.io.IOException; | |
import java.io.InterruptedIOException; |
NewerOlder