Skip to content

Instantly share code, notes, and snippets.

View eltercero's full-sized avatar
🍥

Víctor Martín eltercero

🍥
View GitHub Profile
@eltercero
eltercero / TurnipPrices.cpp
Created April 8, 2020 20:35 — forked from Treeki/TurnipPrices.cpp
AC:NH turnip price calculator
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
// munged from https://github.com/simontime/Resead
namespace sead
{
class Random
{
@eltercero
eltercero / eltercero.itermcolors
Last active February 28, 2020 08:20
Es básicamente el railscasts theme pero en iterm. Así que todo bien.
<?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>Ansi 0 Color</key>
<dict>
<key>Alpha Component</key>
<real>1</real>
<key>Blue Component</key>
<real>0.20000001788139343</real>
### Keybase proof
I hereby claim:
* I am eltercero on github.
* I am eltercero (https://keybase.io/eltercero) on keybase.
* I have a public key ASC2fesALFEAOiAlacuklvGKoUPfGyxs3B1Ag-WAnbj9pQo
To claim this, I am signing this object:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>author</key>
<string>github.com&#x2f;jzelenkov</string>
<key>colorSpaceName</key>
<string>sRGB</string>
<key>gutterSettings</key>
<dict>
@eltercero
eltercero / Package Control.sublime-settings
Created November 17, 2016 09:06
Package Control.sublime-settings
{
"bootstrapped": true,
"in_process_packages":
[
],
"installed_packages":
[
"Advanced CSV",
"AdvancedNewFile",
"AlignTab",
@eltercero
eltercero / gist:1fc5aa57309faf39caad
Created February 8, 2016 10:08 — forked from markbates/gist:4240848
Getting Started with Rack

If you're writing web applications with Ruby there comes a time when you might need something a lot simpler, or even faster, than Ruby on Rails or the Sinatra micro-framework. Enter Rack.

Rack describes itself as follows:

Rack provides a minimal interface between webservers supporting Ruby and Ruby frameworks.

Before Rack came along Ruby web frameworks all implemented their own interfaces, which made it incredibly difficult to write web servers for them, or to share code between two different frameworks. Now almost all Ruby web frameworks implement Rack, including Rails and Sinatra, meaning that these applications can now behave in a similar fashion to one another.

At it's core Rack provides a great set of tools to allow you to build the most simple web application or interface you can. Rack applications can be written in a single line of code. But we're getting ahead of ourselves a bit.

@eltercero
eltercero / init.lua
Last active June 22, 2019 12:29
Config file for hammerspoon
local hotkey = require "hs.hotkey"
local application = require "hs.application"
-- HOTKEYS
local hyper = {"ctrl", "alt", "cmd"}
local app_opener = {"cmd", "ctrl"}
function toggle_app(app_name)
return function()
local app = hs.appfinder.appFromName(app_name)
@eltercero
eltercero / email.yml
Created August 6, 2015 10:42
ActionMailer with Gmail
development:
:address: smtp.gmail.com
:port: 587
:authentication: plain
:user_name: "" #user@gmail.com
:password: "" #password
:enable_starttls_auto: true
@eltercero
eltercero / klass.sublime-snippet
Created July 17, 2015 13:05
Snippet for creating a class with its attributes
<!--
Easily creates something like:
class Object
attr_reader :attr1, :attr2, :attr3
def initialize attr1, attr2, attr3
@attr1 = attr1
@attr2 = attr2
@attr3 = attr3