- Startups for the rest of us
- The Rocketship Podcast
- StartUp Podcast
- Seth Godin's Startup School (finished but worth listening to existing episodes)
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
let(:key) { "I've got the key" } | |
let(:secret) { "I've got the secret" } | |
let(:refresh_token) { "I've got the key to another way" } | |
let(:token) { "Ah ah ah ah ah ah, aha aha" } | |
let(:iv) { "Ah ah ah ah ah" } |
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
config.appender(Hatchet::LoggerAppender.new) do |appender| | |
appender.file = 'log/application.log' | |
# Could delegate to: | |
# self.logger = Logger.new('log/application.log') | |
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
config.appender(Hatchet::LoggerAppender.new) do |appender| | |
appender.device = Logger.new('log/application.log') | |
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
config.hatchet.configure do |hatchet| | |
require 'rbconfig' | |
hatchet.backtrace_filters Bundler.bundle_path.to_s => '[BUNDLER]', | |
Bundler.bin_path.to_s => '[BUNDLER]', | |
Rails.root.to_s => '[RAILS_ROOT]', | |
RbConfig::CONFIG['sitelibdir'] => '[SITELIBDIR]', | |
RbConfig::CONFIG['rubylibdir'] => '[RUBYLIBDIR]', | |
RbConfig::CONFIG['libdir'] => '[LIBDIR]', | |
RbConfig::CONFIG['sitedir'] => '[SITEDIR]' |
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 java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.net.HttpURLConnection; | |
import java.net.URL; | |
public final class Example { | |
public static void main(String[] args) throws IOException { | |
String url = "https://api.onediary.com/v1/events?from=2014-12-17&to=2014-12-18&tzid=Europe/Lisbon"; | |
String token = "REPLACE_WITH_YOUR_TOKEN"; |
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
public static class ServiceBusExtensions | |
{ | |
public static bool HasSubscribersFor<T>(this IServiceBus serviceBus, T message) | |
{ | |
IEnumerable<Action<object>> enumerable = serviceBus.OutboundPipeline.Enumerate(message); | |
return enumerable.Any(); | |
} | |
} |
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
<html> | |
<head></head> | |
<body> | |
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> | |
<script type="text/javascript"> | |
$(function() { | |
$("button").click(function() { | |
$("form").append( | |
$("<input />") | |
.attr("type", "hidden") |
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
$(".container").each(function() { | |
var that = $(this); | |
that.find("img").load(function() { | |
that.append("<span>" + $(this).height() + "</span>"); | |
}); | |
}); |
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 elementsToHash = function(elements) { | |
var hash = {}; | |
elements.each(function() { | |
var element = $(this); | |
hash[element.attr("name")] = element.val(); | |
}); | |
return hash; | |
} |
OlderNewer