These rules are adopted from the AngularJS commit conventions.
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
| #include <assert.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <stdint.h> | |
| #include <stdio.h> | |
| #define N (100000063/64) | |
| struct bitset { | |
| uint64_t bits[N]; |
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 bash | |
| # https://github.com/shadowsocks/shadowsocks-rust/releases | |
| export SSVERSION=v1.23.5 | |
| export SSPORT=443 | |
| export SSPASSWORD="CHANGEME" | |
| export SSARCHIVE="shadowsocks-${SSVERSION}.x86_64-unknown-linux-gnu.tar.xz" | |
| #export SSARCHIVE="shadowsocks-${SSVERSION}.aarch64-unknown-linux-gnu.tar.xz" | |
| export PREFIX=/usr/local/bin |
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
| // | |
| // PerformanceMonitor.m | |
| // SuperApp | |
| // | |
| // Created by qianjianeng on 15/11/12. | |
| // Copyright © 2015年 Tencent. All rights reserved. | |
| // | |
| #import "PerformanceMonitor.h" | |
| #import <mach/mach.h> |
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
| // Update: Hey Folks - I've got a full Gulpfile with everything else over at https://github.com/wesbos/React-For-Beginners-Starter-Files | |
| var source = require('vinyl-source-stream'); | |
| var gulp = require('gulp'); | |
| var gutil = require('gulp-util'); | |
| var browserify = require('browserify'); | |
| var reactify = require('reactify'); | |
| var babelify = require('babelify'); | |
| var watchify = require('watchify'); | |
| var notify = require('gulp-notify'); |
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 threading | |
| import time | |
| class ThreadingExample(object): | |
| """ Threading example class | |
| The run() method will be started and it will run in the background | |
| until the application exits. | |
| """ |
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
| git log | |
| git reset --hard <commit-id> | |
| git push <remote-repo> HEAD --force |
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 time | |
| from datetime import datetime, date | |
| # 今天 | |
| datetime.datetime.today().date().isoformat() | |
| # 通过日期对象生成时间戳 | |
| int(time.mktime(datetime.now().timetuple())) | |
| # 通过时间戳生成日期对象,timestamp 的时间戳以秒为单位 |
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
| // | |
| // CLLocation+Sino.h | |
| // | |
| // Created by i0xbean@gmail.com on 13-4-26. | |
| // 火星坐标系转换扩展 | |
| // | |
| // earth(国外 WGS84), mars(国内 GCJ-02), bearPaw(百度 BD-09) 坐标系间相互转换 | |
| // 未包含 mars2earth. 需要这个可参考 http://xcodev.com/131.html | |
| #import <CoreLocation/CoreLocation.h> |
NewerOlder