Skip to content

Instantly share code, notes, and snippets.

View dawncold's full-sized avatar
🎯
Focusing

Zhen Tian dawncold

🎯
Focusing
View GitHub Profile
// paths and constants
var path = require('path')
var SRC_PATH = path.resolve('./src')
var DIST_PATH = path.resolve('./build')
var OUTPUT_FILENAME = '[name].[chunkhash].js'
var DEV_REGEXP = (/(^babel-?.*|.*-plugin$|.*-loader)/)
var DOT_ENV_SAMPLE_PATH = path.resolve('./.env.default')
var DOT_ENV_PATH = path.resolve('./.env')
var pkg = require('./package.json')
@JasonDeving
JasonDeving / Max Number with es6
Created May 1, 2016 05:37
FInd the max number with es6 with an array.
let numbers = [4,6,3,8];
let max = Math.max(...numbers);
console.log(max);
@allex
allex / gist:11203573
Last active December 5, 2023 07:27
Ubuntu 安装中文字体

环境 (Environment)

版本:Ubuntu 14.04 LTS 默认语言:English(United States)

安装 (Setup)

Debian 和 Ubuntu 下对中文支持比较好的字体有: fonts-droid、ttf-wqy-zenhei 和 ttf-wqy-microhei 等,除了文泉驿系列字体外,比较流行的免费中文字体还有文鼎提供的楷体和上海宋,包名分别是: fonts-arphic-ukai 和 fonts-arphic-uming。

@chuangbo
chuangbo / README.md
Last active June 19, 2023 04:48
Python dynamic DNSPod DNS Script

替换上你的 API Token,域名ID,记录ID等参数,就可以运行了。 会在后台一直运行,每隔30秒检查一遍IP,如果修改了就更新IP。

获取 API Token 的方式

获得 domain_id 可以用 curl

curl -k https://dnsapi.cn/Domain.List -d "login_token=TOKEN"`