Skip to content

Instantly share code, notes, and snippets.

Avatar

raghu bhupatiraju raghuvarmabh

View GitHub Profile
View joel coding challenge.patch
From 98e66e960491f10d543686211b30c3c6a8d61192 Mon Sep 17 00:00:00 2001
From: ydarbleoj <brady.joel@gmail.com>
Date: Tue, 16 Oct 2018 15:11:17 -0700
Subject: [PATCH 1/4] Added event model and migration
---
app/models/event.rb | 3 +++
db/migrate/20181016215050_create_events.rb | 11 +++++++++++
db/schema.rb | 10 +++++++++-
test/fixtures/events.yml | 13 +++++++++++++
View generate document from google sheets
function onOpen() {
var ui = SpreadsheetApp.getUi();
// Or DocumentApp or FormApp.
ui.createMenu('XYZ Menu')
.addItem('Generate PO', 'createDcument')
.addToUi();
}
function createDcument() {
var activeSheet = SpreadsheetApp.getActiveSpreadsheet();
@raghuvarmabh
raghuvarmabh / restaurant.rb
Created Jul 10, 2018
Bare minimum rails project to experiment on models
View restaurant.rb
# Instead of loading all of Rails, load the
# particular Rails dependencies we need
require 'sqlite3'
require 'active_record'
require 'pry'
# Set up a database that resides in RAM
ActiveRecord::Base.establish_connection(
adapter: 'sqlite3',
database: ':memory:'