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
#include <math.h> | |
/** | |
* 3v3 --- [10K] -+- [NTC] --- GND | |
* | | |
* +-- ADC | |
*/ | |
#define NTC_V 3300 | |
#define NTC_R_PULLUP 10000 | |
#define NTC_R(v) (NTC_R_PULLUP * (v) / (NTC_V - (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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
class VagrantPlugins::ProviderVirtualBox::Config < Vagrant.plugin("2", :config) | |
def update_customizations(customizations) | |
@customizations = customizations | |
end | |
end | |
class VagrantPlugins::ProviderVirtualBox::Action::Customize |
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
#!/bin/bash | |
if tty | fgrep -q pts ; then | |
export LANG=zh_CN.UTF-8 | |
fi |
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
This Gist confirms the Linked Identity in my OpenPGP key, and links it to this GitHub account. | |
Token for proof: | |
[Verifying my OpenPGP key: openpgp4fpr:b4448800f2129cd9e136bfffb64fdf3b2d8b022c] |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
stages: | |
- build | |
compile: | |
stage: build | |
script: | |
- go build -ldflags "-s -w -X main.Version=$CI_COMMIT_TAG" | |
artifacts: | |
name: "$CI_PROJECT_NAME-$CI_COMMIT_TAG" | |
paths: |
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
<?php | |
$directly = ['11', '12', '31', '50', '81', '82']; | |
$names = [ | |
'拉祜族佤族布朗族傣族自治县', '保安族东乡族撒拉族自治县', '彝族哈尼族拉祜族自治县', '傣族拉祜族佤族自治县', | |
'哈尼族彝族傣族自治县', '彝族回族苗族自治县', '布依族苗族自治县', '布依族苗族自治州', '白族普米族自治县', | |
'苗族瑶族傣族自治县', '傣族景颇族自治州', '独龙族怒族自治县', '哈尼族彝族自治县', '哈尼族彝族自治县', '哈尼族彝族自治州', | |
'满族蒙古族自治县', '蒙古族藏族自治州', '苗族布依族自治县', '苗族土家族自治县', '土家族苗族自治县', '壮族苗族自治州', | |
'土家族苗族自治州', '仡佬族苗族自治县', '藏族羌族自治州', '傣族佤族自治县', '傣族彝族自治县', '哈萨克族自治县', | |
'回族土族自治县', '回族彝族自治县', '柯尔克孜自治州', '黎族苗族自治县', '苗族侗族自治县', '苗族侗族自治州', |
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
#!/bin/sh | |
export GIT_SSH_COMMAND='ssh -o ProxyCommand="connect -S 127.0.0.1:1080 %h %p"' | |
git config --global core.sshCommand 'ssh -o ProxyCommand="connect -S 127.0.0.1:1080 %h %p"' | |
git clone -c=core.sshCommand 'ssh -o ProxyCommand="connect -S 127.0.0.1:1080 %h %p"' [email protected]:larryli/ipv4.git | |
git config core.sshCommand 'ssh -o ProxyCommand="connect -S 127.0.0.1:1080 %h %p"' |
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 | |
#coding=utf-8 | |
# | |
# Generate a list of dnsmasq rules with ipset for gfwlist | |
# | |
# Copyright (C) 2014 http://www.shuyz.com | |
# Ref https://code.google.com/p/autoproxy-gfwlist/wiki/Rules | |
import urllib2 | |
import re |
NewerOlder