Skip to content

Instantly share code, notes, and snippets.

Avatar

Jeduan Cornejo jeduan

View GitHub Profile
View datePicker.json
{
"__typename": "SectionContainer",
"id": "U2VjdGlvbkNvbnRhaW5lcjo1MDg0MTQ4OTA2NjUzMTE0MDUx",
"sectionComponentType": "EXPLORE_FILTER_VERTICAL_DATES",
"sectionContentStatus": null,
"sectionId": "LOCATION_FLOW:EXPLORE_SEARCH_DATE_PICKER",
"errors": [],
"sectionDependencies": [],
"enableDependencies": [],
"disableDependencies": [],
@jeduan
jeduan / index.mjs
Last active Dec 7, 2021
Anchor.build.js
View index.mjs
import BN from 'bn.js';
export { default as BN } from 'bn.js';
import { sendAndConfirmRawTransaction, PublicKey, Transaction, TransactionInstruction, SystemProgram } from '@solana/web3.js';
import * as web3_js from '@solana/web3.js';
export { web3_js as web3 };
import { Buffer } from 'buffer';
import camelCase from 'camelcase';
import * as borsh from '@project-serum/borsh';
import bs58$1 from 'bs58';
import { sha256 as sha256$1 } from 'js-sha256';
@jeduan
jeduan / Info.plist
Created Feb 9, 2020
PokeAPI Launchbar Action
View Info.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleIconFile</key>
<string>com.spotify.client</string>
<key>LBTextInputTitle</key>
<string>Spotify</string>
<key>CFBundleIdentifier</key>
<string>com.kyleacarson.LaunchBar.action.SearchSpotify</string>
View satori_session_id.json
/s/San-Francisco--CA--United-States/all
{
"context": {
"timestamp": 1533239479462,
"source": "monorail",
"platform": "js",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.84 Safari/537.36",
"version": "Unknown",
"bev": "1528237098_ZCHxUd7T3XDqi7CM",
"user_id": 129901766,
@jeduan
jeduan / apiTwitter.js
Last active Feb 23, 2016
Implementing Twitter's OAuth with only request
View apiTwitter.js
import request from 'request-promise'
import {parse as qsparse} from 'querystring'
import parse from 'co-body'
var post = request.defaults({json: true}).post
const TWITTER_KEY = ''
const TWITTER_SECRET = ''
const TWITTER_CALLBACK_URL = ''
export function * requestToken () {
@jeduan
jeduan / wifi-password.rb
Last active Aug 29, 2015
Homebrew Formulae for wifi-password
View wifi-password.rb
class WifiPassword < Formula
homepage "https://github.com/rauchg/wifi-password"
url "https://github.com/rauchg/wifi-password/archive/0.0.1.tar.gz"
version "0.0.1"
sha1 "7f92794a3a04762009a0c4525cbf2aa851002289"
def install
bin.install "wifi-password.sh" => "wifi-password"
end
end
@jeduan
jeduan / keybase.md
Last active Aug 29, 2015
keybase.md
View keybase.md

Keybase proof

I hereby claim:

  • I am jeduan on github.
  • I am jeduan (https://keybase.io/jeduan) on keybase.
  • I have a public key whose fingerprint is B70B 4F2F 27B9 18F5 4100 0EBE 6709 8BD2 7AEF CF68

To claim this, I am signing this object:

View db.js
var _ = require('underscore')
var config = require('../../config')
var mongoose = require('mongoose')
mongoose.connect(config.mongoUrl)
var db = mongoose.connection
mongoose.set('debug', !!config.mongoDebug)
db.on('error', function () {
return console.error.bind(console, '[mongo]: ')
})
@jeduan
jeduan / index.js
Created Mar 20, 2014
Error handling in express 4
View index.js
var express = require('express'),
logger = require('morgan')
var app = express();
var env = process.env.NODE_ENV || 'development';
var silent = env === 'test'
app.set('port', +process.env.PORT || 3000)
if (env === 'development') {
@jeduan
jeduan / database.lua
Created Jan 20, 2014
Creating a model that renders itself in corona
View database.lua
local modeloEspecial = ModeloEspecial:new {
name = "yogodb",
debug = settings.debugSql
}
local function migrate(schemaVersion, exec)
if schemaVersion < 1 then
log "migrating schema to v1"
local createPlayers = [[CREATE TABLE IF NOT EXISTS players (