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
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
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
var crypto = require("crypto"); | |
var moment = require("moment") | |
var s3 = { | |
generateS3Policy: function (fileName) { | |
var s3Policy = { | |
'conditions': [ | |
{'bucket': CONF.s3.bucket}, | |
['starts-with', '$key', 'uploads/' + fileName], | |
{'acl': 'public-read'}, |
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
local ffi = require "ffi" | |
local sha512 = require "resty.sha512" | |
local aes = require "resty.aes" | |
local ffi_new = ffi.new | |
local ffi_str = ffi.string | |
local C = ffi.C | |
local setmetatable = setmetatable | |
local error = error |
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
<link rel="import" href="../chart-js/chart-js.html"> | |
<link rel="import" href="../core-ajax/core-ajax.html"> | |
<polymer-element name="my-element"> | |
<template> | |
<style> | |
:host { | |
position: absolute; | |
width: 100%; |
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
listen 9191 default_server; | |
server_tokens off; | |
location / { | |
# proxy_pass 'http://ajaytestsomething.appspot.com/'; | |
resolver 8.8.8.8; | |
content_by_lua ' | |
-- http://www.w3.org/Protocols/rfc2616/rfc2616-sec13.html#sec13.5.1 | |
local HOP_BY_HOP_HEADERS = { |
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
location / { | |
add_header 'Access-Control-Allow-Origin' '*'; | |
add_header 'Access-Control-Allow-Credentials' 'true'; | |
add_header 'Access-Control-Allow-Methods' 'GET, POST,PUT,OPTIONS,DELETE,PATCH'; | |
add_header 'Access-Control-Allow-Headers' 'DNT,X-CustomHeader,Keep-Alive,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type'; | |
if ($request_method = 'OPTIONS') { | |
add_header 'Access-Control-Allow-Origin' '*'; |
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
<dependency> | |
<groupId>org.seleniumhq.selenium</groupId> | |
<artifactId>selenium-java</artifactId> | |
<version>2.3.1</version> | |
</dependency> |
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
new WebDriverWait(driver, 45) { | |
}.until(new ExpectedCondition<Boolean>() { | |
@Override | |
public Boolean apply(WebDriver drv) { | |
return drv.findElement(By.id("stateProvinceDropdown-US")) | |
.isDisplayed(); | |
} | |
}); |
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
/** Like assertEquals, but fails at the end of the test (during tearDown) */ | |
public void verifyEquals(boolean s1, boolean s2) { | |
try { | |
assertEquals(new Boolean(s1), new Boolean(s2)); | |
} catch (Error e) { | |
verificationErrors.append(throwableToString(e)); | |
} | |
} |
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
Checkout from http://google-styleguide.googlecode.com/svn/trunk, revision HEAD, Fully recursive, Externals included | |
C:\styles\styleguide.xsl | |
C:\styles\javascriptguide.xml | |
C:\styles\xmlstyle.html | |
C:\styles\google_python_style.vim | |
C:\styles\google-c-style.el | |
C:\styles\objcguide.xml | |
C:\styles\cppguide.xml | |
C:\styles\intellij-java-google-style.xml | |
C:\styles\styleguide.css |
OlderNewer