Skip to content

Instantly share code, notes, and snippets.

View alejandrosuarez's full-sized avatar
💭
🎶... Don't tell me you're too blind to see... 😎 Never gonna...🕺

Alejandro Suarez alejandrosuarez

💭
🎶... Don't tell me you're too blind to see... 😎 Never gonna...🕺
View GitHub Profile
@gregoryvit
gregoryvit / WebViewBasedPlayground.swift
Last active September 28, 2023 18:03
WebView based Swift playground
//: Playground - noun: a place where people can play
import UIKit
import PlaygroundSupport
class ViewController:UIViewController{
lazy var webView: UIWebView = UIWebView(frame: self.view.bounds)
override func viewDidLoad() {
@alejandrosuarez
alejandrosuarez / move_to_rds.rb
Created November 25, 2015 06:29 — forked from guenter/move_to_rds.rb
A quick and dirty script to move a database into Amazon RDS (or any other database). Can transfer part of the data beforehand.
require 'fileutils'
start_time = Time.now
SOURCE_DB = {
:name => 'db_name',
:user => 'db_user',
:password => 'db_pass',
:host => 'localhost'
#https://gorails.com/setup/ubuntu/14.04
sudo apt-get update
sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties
sudo apt-get install libgdbm-dev libncurses5-dev automake libtool bison libffi-dev
curl -L https://get.rvm.io | bash -s stable
source ~/.rvm/scripts/rvm
echo "source ~/.rvm/scripts/rvm" >> ~/.bashrc
rvm install 2.1.2
rvm use 2.1.2 --default