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/python | |
# encoding=utf-8 | |
# api | |
# https://www.qcloud.com/document/product/275/6101 | |
import httplib, urllib | |
import json | |
import time | |
import base64 |
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
good, 你已经有了一个自己的shadowsocks代理了,现在想要把这个代理公布出去给所有人分享。 | |
但是没有两个小时,代理就没法使用了,为什么?因为你需要额外注意以下事项(以下步骤需要比较高的linux技能) | |
本文只关注于确保shadowsocks服务还“活着”,如果你希望让其跑得更快,请参考 | |
https://github.com/clowwindy/shadowsocks/wiki/Optimizing-Shadowsocks | |
1、 shadowsocks的timeout设置 | |
超时时间越长,连接被保持得也就越长,导致并发的tcp的连接数也就越多。对于公共代理,这个值应该调整得小一些。推荐60秒。 | |
2、 检查操作系统的各种限制 | |
对于openvz的vps,特别需要检查一下 |
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
1. 下载高版本xcode并安装 例如名字为 Xcode-beta.app | |
2. 将高版本Xcode中的设备支持链接到低版本的Xcode中 | |
~~~ | |
ln -s /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/$(iosVersion) /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport | |
# 例如在低版本中指出ios10.2 | |
ln -s /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/10.2\ \(14C5062c\)/ /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport | |
~~~ | |
3. 重开低版本的Xcode就可以调试高版本IOS了 |
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
oldnum=$(/usr/libexec/PlistBuddy -c "Print CFBundleVersion" "${PROJECT_DIR}/${INFOPLIST_FILE}") | |
if [[ ! -f "lastbuildnumber" ]]; then | |
echo $oldnum > "lastbuildnumber" | |
fi | |
lastnum=`cat lastbuildnumber` | |
#lastnum=fdsafd | |
echo "lastnum=${lastnum}" |
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
-- split utf8 char | |
function string.splitUtf8(str) | |
local list = {} | |
local p = 1 | |
for i = 1, #str do | |
local c = string.byte(str, i) | |
if c < 0x80 then | |
-- ascii | |
table.insert(list, string.sub(str, p, i)) | |
p = i + 1 |
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
using UnityEngine; | |
using UnityEditor; | |
using UnityEditor.Callbacks; | |
using UnityEditor.iOS.Xcode; | |
using System.IO; | |
public class PbxModifier | |
{ | |
[PostProcessBuild] | |
public static void OnPostprocessBuild(BuildTarget buildTarget, string path) |
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
local FrameTaskExt = {} | |
FrameTaskExt.__index = FrameTaskExt | |
-- isFinish, isContinue function taskFunc(times) | |
function FrameTaskExt.new(taskFunc) | |
local o = {} | |
setmetatable(o, FrameTaskExt) | |
o:_init(taskFunc) | |
return o | |
end |
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
// CameraFacing.cs | |
// original by Neil Carter (NCarter) | |
// modified by Hayden Scott-Baron (Dock) - http://starfruitgames.com | |
// allows specified orientation axis | |
using UnityEngine; | |
using System.Collections; | |
public class CameraFacing : MonoBehaviour |
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
/** | |
* Created by rodrigo on 12/14/13. | |
*/ | |
package rodrigolopezpeker.genome2d.text { | |
import com.genome2d.textures.GTexture; | |
import flash.utils.Dictionary; | |
public class BitmapChar { |
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
function string.utf8len(s) | |
if s == nil or s == "" then return 0 end | |
local n = 0 | |
for i = 1, #s do | |
local c = string.byte(s, i) | |
if c < 0x80 or c >= 0xC0 then | |
n = n + 1 | |
end | |
end |