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
[daniel@Europa:Desktop]: python riak_test.py | |
Inserting 0 | |
Inserting 1000 | |
Inserting 2000 | |
Inserting 3000 | |
Inserting 4000 | |
Inserting 5000 | |
Inserting 6000 | |
Inserting 7000 | |
Inserting 8000 |
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 <Foundation/Foundation.h> | |
#import "Sparrow.h" | |
/// An SXGauge displays a texture, trimmed to its left side, depending on a ratio. | |
/// This can be used to display a progress bar or a time gauge. | |
@interface SXGauge : SPSprite | |
{ | |
@private | |
SPImage *mImage; | |
float mRatio; |
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
package starling.extensions | |
{ | |
import flash.display3D.Context3D; | |
import flash.geom.Point; | |
import flash.geom.Rectangle; | |
import starling.core.RenderSupport; | |
import starling.core.Starling; | |
import starling.display.DisplayObject; | |
import starling.display.Sprite; |
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
From: http://snipt.net/yonishin/about-xcode-4-project-template | |
XCode 4 Projects and Files Template Folder: /Developer/Library/Xcode/Templates | |
Examples: | |
/Developer/Library/Xcode/Templates/Project Templates/Base/Other/Empty.xctemplate | |
/Developer/Library/Xcode/Templates/Project Templates/Base/Base.xctemplate | |
/Developer/Library/Xcode/Templates/Project Templates/Mac/Mac Base.xctemplate | |
/Developer/Library/Xcode/Templates/Project Templates/Mac/Application/Command Line Tool.xctemplate | |
/Developer/Library/Xcode/Templates/Project Templates/Mac/Application/Cocoa Application.xctemplate |
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 mox | |
import stubout | |
#test function tearup | |
m = mox.Mox() | |
BigWorld = m.CreateMockAnything() | |
m.StubOutWithMock(BigWorld,"entities") | |
m.StubOutWithMock(BigWorld,"singleton") | |
#Great,prepare clientside input data for function be called. | |
BigWorld.entities.get(100).AndReturn(None) |
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 python | |
import paramiko | |
hostname = 'localhost' | |
port = 22 | |
username = 'foo' | |
password = 'xxxYYYxxx' | |
if __name__ == "__main__": |
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 | |
# | |
#Notice:Please close domain lookup on your router or switch. | |
__author__="ring0" | |
__date__ ="$2011-6-5 16:00:00$" | |
__version__ ="0.3" | |
import sys | |
try: |
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
child = pexpect.spawn('su 3028') | |
child.expect(".word") | |
child.sendline("3028") | |
child.expect(".$") | |
child.sendline('cd ~') | |
child.sendline('/home/exe/mf204/bigworld/tools/server/control_cluster.py check') | |
r = child.expect([".not run",".run",pexpect.EOF]) | |
if r == 0: | |
child.sendline('/home/exe/mf204/bigworld/tools/server/control_cluster.py load simple') | |
print 'try load server' |
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 os | |
filters = ['.cpp','.h','.py','.hpp','.ipp','.sln','.vcproj','.mak'] | |
filters.extend(['.c','python','Makefile','php']) | |
#filters = ['python'] | |
#filters = ['*'] | |
if os.name == 'posix': | |
FOLDER_FIX = '/' | |
else: | |
FOLDER_FIX = "\\" |
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 python | |
#svn log -v -r 20146:20150 svn://192.168.1.230/tjspaces | |
#Author cnsoft 2011-09 | |
svncmd = "svn log -v -r %d:%d %s" | |
#Test | |
svnurl = "svn://192.168.1.230/tjspaces/" | |
# | |
outputpath = "d:\\packagetools" |
OlderNewer