This file contains 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
// | |
// UIColor Extension.swift | |
// Uses Swift 2.0 | |
// | |
// Created by Ryan Collins on 9/22/15. | |
// | |
// | |
import Foundation | |
import UIKit |
This file contains 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 PerfectLib | |
//public method that is being called by the server framework to initialise your module. | |
public func PerfectServerModuleInit() { | |
// Install the built-in routing handler. | |
// Using this system is optional and you could install your own system if desired. | |
Routing.Handler.registerGlobally() | |
// Create Routes | |
Routing.Routes["GET", ["/", "index.html"] ] = { (_:WebResponse) in return IndexHandler() } |
This file contains 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 | |
from urllib import urlencode | |
import httplib2, base64, json | |
filewithdomains = '/path/to/domains.txt' | |
resellerlogin = 'root' | |
resellerpass = 'password' | |
whmip = '123.456.789.000' |
This file contains 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 | |
from urllib import urlencode | |
import httplib2, base64, json | |
filewithdomains = '/path/to/domains.txt' | |
resellerlogin = 'root' | |
resellerpass = 'password' | |
whmip = '123.456.789.000' |
This file contains 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 urllib2 as ur | |
import re | |
f = ur.urlopen(u'http://website.com/SiteMap.xml') | |
res = f.readlines() | |
for d in res: | |
data = re.findall('<loc>(http:\/\/.+)<\/loc>',d) | |
for i in data: | |
print i |
This file contains 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
~/Library/Containers/com.apple.iWork.Pages/Data/Library/Application Support/User Templates |
This file contains 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
#element li { | |
border: 1px solid #000; | |
display: -moz-inline-stack; | |
display: inline-block; | |
vertical-align: top; | |
zoom: 1; | |
*display: inline; | |
_height: 250px; | |
} |
This file contains 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 rebuild | |
swift build --clean; and swift build | |
end |
This file contains 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 cleanbuild | |
swift build --clean=dist; and swift build | |
end |
This file contains 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
#if os(Linux) | |
import SwiftGlibc | |
public func arc4random_uniform(_ max: UInt32) -> Int32 { | |
return (SwiftGlibc.rand() % Int32(max-1)) | |
} | |
#endif |
OlderNewer