This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ssh git@github.com -v | |
OpenSSH_5.2p1, OpenSSL 0.9.8l 5 Nov 2009 | |
debug1: Reading configuration data /etc/ssh_config | |
debug1: Connecting to github.com [207.97.227.239] port 22. | |
debug1: Connection established. | |
debug1: identity file /Users/daze/.ssh/identity type -1 | |
debug1: identity file /Users/daze/.ssh/id_rsa type 1 | |
debug1: identity file /Users/daze/.ssh/id_dsa type -1 | |
debug1: Remote protocol version 2.0, remote software version OpenSSH_5.1p1 Debian-5github2 | |
debug1: match: OpenSSH_5.1p1 Debian-5github2 pat OpenSSH* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Controller | |
class RestaurantsController < ApplicationController | |
def show | |
@restaurant = Restaurant.find(params[:id]) | |
respond_to do |format| | |
format.html # show.html.erb | |
format.js # show.js.coffee | |
end | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def mealtimes(meal) | |
arr = [meal.breakfast, meal.lunch, meal.dinner] | |
if arr == [true, true, true] | |
"breakfast, lunch, and dinner" | |
elsif arr == [false, false, false] | |
"" | |
elsif arr == [true, true, false] | |
"breakfast and lunch" | |
elsif arr == [true, false, true] | |
"breakfast and dinner" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(".memory").hover -> | |
memory = $(this).attr('id') | |
id = memory.split('_')[1] # get id of e.g. memory_4 | |
#find memory | |
time_frames = <% Memory.find(id).time_frames %> | |
for time_frame in time_frames | |
tf_id = time_frame.id | |
$("#"+tf_id).toggle() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Implementation of Application.Memory.Index class | |
jQuery -> | |
@module "Application.Memory", -> | |
class @Index | |
# Needed because the height depends on window size | |
setHeightOfLifeTimeFrame: -> | |
height = `$(document).height()` | |
$('#life_time_frame').css('height', height-50 + 'px'); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('#book').animate({ | |
opacity: 0.25, | |
left: '+=50', | |
height: 'toggle' | |
}, 5000, function() { | |
// Animation complete. | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
////////////////////////////////////////////////////////////////////////////////// | |
// Author: Brandon Franzke | |
// Create Date: 2013-02-04 | |
// Modified: | |
// File Name: ee201_clk_60Hz.v | |
// Description: | |
// | |
// | |
// Revision: 1.1 | |
// Additional Comments: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
`timescale 1ns / 1ps | |
module ee201_roller(Clk, Reset, NewX, X); | |
/* INPUTS */ | |
// Clock & Reset | |
input Clk, Reset; | |
input NewX; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//---------------------------------------------------------------------------- | |
// A verilog module for a ff_reset (based on my vhdl module ff_reset.vhd) | |
// Written by Gandhi Puvvada Date: 2/15/2008 | |
// File name: ff_reset.v | |
// Analyze and simulate for 550ns in modelsim. | |
// Answer all questions posted below. | |
//---------------------------------------------------------------------------- | |
// When you compile this design in synopsys, use the following command so that, | |
// the mapped design can NOT use complex cells with builtin muxes. | |
// set_dont_use lcb500kv/FDS* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ---------------------------------------------------------------------- | |
// A Verilog module for a simple divider | |
// Written by Gandhi Puvvada Date: 7/17/98, 2/15/2008, 10/13/08, 2/21/2010 | |
// File name: divider_combined_cu_dpu.v | |
// ------------------------------------------------------------------------ | |
// This is an improvement over divider.v | |
// We combined the two separate case statements in the divider.v | |
// into one single case statement. | |
// Notice the following lines added because of this combining | |
// X <= 4'bXXXX; // to avoid recirculating mux controlled by Reset |
OlderNewer