Skip to content

Instantly share code, notes, and snippets.

View luckydrq's full-sized avatar

Deng Ruoqi luckydrq

View GitHub Profile
@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"`

High level style in javascript.

Opinions are like assholes, every one has got one.

This one is mine.

Punctuation: who cares?

Punctuation is a bikeshed. Put your semicolons, whitespace, and commas where you like them.

@adamawolf
adamawolf / Apple_mobile_device_types.txt
Last active November 18, 2024 09:05
List of Apple's mobile device codes types a.k.a. machine ids (e.g. `iPhone1,1`, `Watch1,1`, etc.) and their matching product names
i386 : iPhone Simulator
x86_64 : iPhone Simulator
arm64 : iPhone Simulator
iPhone1,1 : iPhone
iPhone1,2 : iPhone 3G
iPhone2,1 : iPhone 3GS
iPhone3,1 : iPhone 4
iPhone3,2 : iPhone 4 GSM Rev A
iPhone3,3 : iPhone 4 CDMA
iPhone4,1 : iPhone 4S
@adammw
adammw / README.md
Created August 3, 2012 06:30
Node.js for Raspberry Pi

Node.js for Raspberry Pi

Pre-built binaries

Recent releases have been pre-built using cross-compilers and this script and are downloadable below.

If you have found these packages useful, give me a shout out on twitter: @adammw

@fcicq
fcicq / smartmachine-survival-guide-fcicq.markdown
Last active December 11, 2015 06:48
SmartMachine 生存指南 by fcicq

SmartMachine 生存指南

by fcicq, CC-BY

SmartMachine 是 Joyent 家的虚拟化方案.
SmartOS 主要的卖点是 ZFS + DTrace + Zones (SmartMachine) + KVM (运行 Linux, Windows 等).
实际上 SmartOS 是 Joyent 以 Solaris 为基础 (因为 OpenSolaris 项目被中止而改名 illumos) 打包的操作系统.

SmartOS 作为 HOST 时, 虽然支持 KVM 虚拟化, 但不支持突发的 vCPU.
而 SmartMachine 是基于 Zones 的 (存储则是 ZFS), 比较类似 Linux 平台下 OpenVZ 或者 LXC 的方案.
资源用量由调度器决定, 只需要修改配额 (ZFS 也支持在线扩展) 就可以伸缩, 所以伸缩不需要重启.

@wolfeidau
wolfeidau / pi-build-deb.sh
Last active August 18, 2021 07:05
Build nodejs from source and assemble a deb package which installs on the Raspberry pi
#!/bin/bash
set -e
set -o errtrace
node_version="0.10.20"
source_bundle="http://nodejs.org/dist/v${node_version}/node-v${node_version}.tar.gz"
# store the location of the base working area.
@yisibl
yisibl / HTML-tags.md
Last active September 15, 2024 14:09
常用的 HTML 头部标签

常用的 HTML 头部标签

详细介绍参见原文:yisibl/blog#1

<!DOCTYPE html> <!-- 使用 HTML5 doctype,不区分大小写 -->
<html lang="zh-cmn-Hans"> <!-- 更加标准的 lang 属性写法 http://zhi.hu/XyIa -->
<head>
    <meta charset='utf-8'> <!-- 声明文档使用的字符编码 -->
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> <!-- 优先使用 IE 最新版本和 Chrome -->
@yisibl
yisibl / git-optimization.md
Last active June 28, 2023 14:59
Git 优化

Git 优化

在前两节中,我们安装完Git后,创建并备份了公钥,这篇教程让我们在使用 Git 时更加得心应手。

优化点

  • 解决各种Git下的中文问题
  • 显示中文文件夹或文件
  • 显示中文git log信息
  • 支持直接在bash输入中文
@yisibl
yisibl / prefix.css
Last active August 29, 2015 13:56
Autoprefixer 测试用例
/**
* Autoprefixer 测试用例
* @author: 一丝
* @update: 2014-2-21 11:26:44;
*/
/* ==========================================================================
常用属性测试
========================================================================== */
@dead-horse
dead-horse / bench.js
Created August 23, 2014 16:20
co benchmark for thunk and promise
var benchmarks = require('beautify-benchmark');
var Benchmark = require('benchmark');
var thunkify = require('thunkify');
var zlib = require('zlib');
var co = require('co');
var fs = require('fs');
var gzipPromise = require('mz/zlib').gzip;
var gzipThunk = thunkify(zlib.gzip);
var fsPromise = require('mz/fs');