Skip to content

Instantly share code, notes, and snippets.

@dashinfall3
dashinfall3 / .json
Created August 26, 2021 19:46
Snowflake JSON Connection - Flywheel
{
" ""account":"the_account",
" ""user":"the_user",
"role":"flywheel_role",
" ""private_key":"-----BEGIN PRIVATE KEY-----\\nS0AsD==\\n-----END PRIVATE KEY-----\\n",
" ""passphrase":"",
" ""type":"SNOWFLAKE"
}
var bigHello = function() {
var greeting = "why hello there!";
var smallHello = function() {
document.writeln(greeting);
};
smallHello();
};
bigHello();
@dashinfall3
dashinfall3 / Analytics_API.rb
Created May 9, 2013 22:47
Accessing Google Analytics
def google_access_token_live?
google_authentication = self.authentications.find(:first, :conditions => { :provider => 'google_oauth2'})
Time.now - google_authentication.updated_at < 3600
end
def google_refresh_access_token
google_authentication = self.authentications.find(:first, :conditions => { :provider => 'google_oauth2'})
consumer_key = ENV['GOOGLE_CONSUMER_KEY']
consumer_secret = ENV['GOOGLE_CONSUMER_SECRET']
client = OAuth2::Client.new(consumer_key, consumer_secret, {:site => 'https://accounts.google.com', :authorize_url => '/o/oauth2/auth', :token_url => '/o/oauth2/token'})
#board {
font-family: monospace;
background-color: #9e8d68;
margin: 0;
padding: 0;
position: relative;
}
.post-it {
position: absolute !important;
@dashinfall3
dashinfall3 / gist_1
Created March 17, 2013 08:18
This gist has been created from CodeCred.me
test
@dashinfall3
dashinfall3 / test2
Created March 17, 2013 01:26
This gist has been created from CodeCred.me
test2
@dashinfall3
dashinfall3 / test3
Created March 17, 2013 01:22
This gist has been created from CodeCred.me
test3
@dashinfall3
dashinfall3 / test2
Created March 17, 2013 01:21
This gist has been created from CodeCred.me
test2
@dashinfall3
dashinfall3 / test2
Created March 17, 2013 01:20
This gist has been created from CodeCred.me
test2
@dashinfall3
dashinfall3 / test2
Created March 17, 2013 01:13
This gist has been created from CodeCred.me
test2