Skip to content

Instantly share code, notes, and snippets.

@zhaozg
zhaozg / Bootstrap3 Web Design Essence.md
Last active November 7, 2018 07:31
Bootstrap3 Web Design Essence

说明

简介

Bootstrap 让前端开发更快速、简单。所有开发者都能快速上手、所有设备都可以适配、所有项目都适用。 Bootstrap3 能够支持从 IE8 开始的说有主流浏览器,用以开发响应式布局,移动设备优先支持的 Web 项目。 Bootstrap3 使用栅格系统布局 Web 前端,提供基本的常用的组件,统一页面风格。严格按照 Bootstrap 框架开发的 Web 项目,能够快速成熟,灵活定制,方便团队共享和复用前端代码,极大地降低开发和维护成本。 Bootstrap3 和其它支持 Bootstrap 的组件和扩展集成后,能够实现复杂,灵活,高效的 Web 应用系统。

精华扩展

@zhaozg
zhaozg / flow.md
Created June 4, 2018 10:02
flow test
st=>start: Start
e=>end: End
op1=>operation: My Operation
sub1=>subroutine: My Subroutine
cond=>condition: Yes or No?
io=>inputoutput: catch something...
@zhaozg
zhaozg / build neovim
Created May 17, 2018 02:01
build.neovim.sh
make CMAKE_BUILD_TYPE=MinSizeRel BUILD_TYPE="Unix Makefiles"
make -C build install
@zhaozg
zhaozg / README.md
Last active September 30, 2017 02:15 — forked from hofmannsven/README.md
My simply Git Cheatsheet
@zhaozg
zhaozg / openssl-build.sh
Created August 15, 2017 13:34 — forked from foozmeat/openssl-build.sh
A shell script to build openssl for iOS and Mac. It currently builds: Mac -> i386 & x86_64 // iOS -> armv7, arm64 // iOS Simulator -> i386 & x86_64.
#!/bin/bash
# This script builds the iOS and Mac openSSL libraries
# Download openssl http://www.openssl.org/source/ and place the tarball next to this script
# Credits:
# https://github.com/st3fan/ios-openssl
# https://github.com/x2on/OpenSSL-for-iPhone/blob/master/build-libssl.sh
@zhaozg
zhaozg / dll2lib.txt
Created June 15, 2017 08:11
Create .lib file from .dll
Create .lib file from .dll
Published December 5, 2008 Game Development , IT 60 Comments
Tags: C#, dll, lib, library, linking
When working with 3rd party win dll’s you somtimes miss the according .lib file required to compile against it. There is a MS KB article showing how to generate a .lib file from a .dll, however the required steps are not described detailed enough I think. So here is my quick guide:
Open the Visual Studio Command Prompt, you find its shortcut in Start->Programs->Microsoft Visual Studio->Tools. Now run the dumpbin command to get a list of all exported functions of your dll:
dumpbin /exports C:\yourpath\yourlib.dll
@zhaozg
zhaozg / android.sh
Created November 3, 2016 06:07
build luajit for android on windows with NDK
PATH=/e/PortableDev/mingw32/bin:$PATH
NDK=/d/server/android/android-ndk-r10e
NDKABI=19
NDKVER=$NDK/toolchains/arm-linux-androideabi-4.9
NDKP=$NDKVER/prebuilt/windows-x86_64/bin/arm-linux-androideabi-
NDKF="--sysroot=$NDK/platforms/android-$NDKABI/arch-arm"
make HOST_CC="/e/PortableDev/mingw32/bin/gcc -m32" CROSS=$NDKP TARGET_FLAGS="$NDKF" TARGET_SYS=LINUX clean default install
@zhaozg
zhaozg / js_pattern.js
Created December 17, 2015 01:42
pattern for bootstrap validoter
ip4addr = ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$
ip4addr CIDR range = ^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\/([0-9]|[1-2][0-9]|3[0-2]))$
ip6addr = ^s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]d|1dd|[1-9]?d)(.(25[0-5]|2[0-4]d|1dd|[1-9]?d)){3}))|:))|(([0-9A-Fa-f]{
@zhaozg
zhaozg / luvit_thread_test.lua
Created August 18, 2015 05:20
luvit_thread_test.lua
local uv = require'uv' --to get new_thread
local luvi = require'luvi' --to get bundle base
local timer = require'timer' --lib in luvit
local interval = timer.setInterval(1000, function ()
print('Main Thread')
end)
print("Main ...running...")
@zhaozg
zhaozg / inproc.lua
Last active August 29, 2015 14:27
luvi thread example
local uv = require('uv')
local nn = require 'nanomsg-ffi'
local ffi = require('ffi')
local ADDRESS = "inproc://abcd"
--ADDRESS = "tcp://127.0.0.1:5556"
local rep = nn.socket( nn.REP )
local sndfd = rep:getsockopt(nn.SOL_SOCKET, nn.SNDFD)