Skip to content

Instantly share code, notes, and snippets.

View cocolote's full-sized avatar
💭
Working on Chromebook

Ezequiel Jose Lopez cocolote

💭
Working on Chromebook
View GitHub Profile
@cocolote
cocolote / AppAcademy_.idea_.name
Created September 4, 2014 04:47
Exercises for App Academy
AppAcademy
@cocolote
cocolote / data.rb
Created January 30, 2015 14:51
Twitter data
def twitter_data
[{"LaunchAcademy_"=>
{"description"=>
"A 10 week, intensive bootcamp teaching you how to code with a focus on Ruby on Rails",
"last twenty tweets"=>
["RT @chrisccerami: While learning web development I created a map of all of the shows @Screamales have played and damn @DonGiovanniRecs http…",
"6 ways to quantify your code and why you need to do it: http://t.co/1WKtpo41tP by @kevinrcasey http://t.co/lulzPLTY8c",
"Do more of what you want at work. How to create productive partnerships: http://t.co/QpYpHhHEid by @benvoss",
"RT @Pistachio: SO rad. bunch of local women learning to code with @gdiBoston at @HubSpot right now: http://t.co/jaIxK7suOj",
"RT @STWatkins78: Huge breakthrough on my breakable toy today...can upload local file to soundcloud from my app...time for a beer! #LaunchAc…",
@cocolote
cocolote / favorite_movies.rb
Created February 4, 2015 16:37
Favorite Movies
favorite_movies = [
{ title: 'The Big Lebowski', year_released: 1998, director: 'Joel Coen', imdb_rating: 8.2 },
{ title: 'The Shining', year_released: 1980, director: 'Stanley Kubrick', imdb_rating: 8.5 },
{ title: 'Troll 2', year_released: 1990, directory: 'Claudio Fragasso', imdb_rating: 2.5 }
]
favorite_movies.each{ |movie| puts "#{movie[:year_released]}: #{movie[:title]}" }
@cocolote
cocolote / Rails-assets-pipe.md
Last active August 29, 2015 14:21
Rails: How to fix the assets pipe to work with Heroku

The annoying Assets Pipe problem with Heroku and Rails

1_ in config/environments/production.rb

Set config.assets.compile = false to config.assets.compile = true

2_ in config/application.rb

Add the line config.assets.compile = true

@cocolote
cocolote / DM-CFML.md
Last active August 29, 2015 14:24
Decision Making structures ColdFusion

#Decision Making Structures

  • Operators

CFML and CFScirpt | CF8+ CFScript Only --- | --- | --- IS, EQUAL, EQ | == IS NOT, NOT EQUAL, NEQ | != GT, GREATER THAN, LT, LESS THAN, GTE, LTE | >, <, >=, <= CONTAINS | N/A

@cocolote
cocolote / Params-Forms-CFML.md
Last active August 29, 2015 14:24
The params array of CFML

Setting variables and sending values with forms CFML

  1. Set the variables to use with the form under line
<cfparam name = "form.contactname" default = "" />
<cfparam name = "form.email" default = "" />
<cfparam name = "form.message" default = "" />
<cfparam name = "form.submitted" default = "0" />
@cocolote
cocolote / loop-CF.md
Last active August 29, 2015 14:24
wild loops

Loops

  • The old for loop

cfloop have step attribute that you can use it to: increment in a different pase or decrement using negative numbers step = "-1" this would decrement 1 by one

@cocolote
cocolote / win-network-commands.md
Last active August 29, 2015 14:24
Some windows network commands

#Windos Network Commands

###nslookup The nslookup tool can help you to verify that DNS name resolution is working correctly. When you run nslookup against a host name, the tool will show you how the name was resolved, as well as which DNS server was used during the lookup. This tool can be extremely helpful when troubleshooting problems related to legacy DNS records that still exist but that are no longer correct. To use this tool, just enter the nslookup command, followed by the name of the host you want to resolve. For example:

nslookup tsdata.ts24

###netstat -an The netstat command is particularly useful, displaying all sorts of network statistics when used with its various options. One of the most interesting variants of netstat is netstat -an, which will display a list of all open network connections on their computer, along with the port they’re using and the foreign IP address they’re connected to.

@cocolote
cocolote / apache-installation.md
Last active August 29, 2015 14:24
Apache Installation

#Install Apache server on Windows 7 64 with IIS running

Check first if you have the dependencies installed in your computer. You need Visual C++ 2008 Redistributable Package Open the control panel (window+r type "control" and press "enter") check if you see the package installed.

Get the Apache .zip. This is and official third party site, Apache does not provide a package to install in windows, you would have to build it manually.

Unzip the file and move or copy its content into C:\Apache22

To start Apache open a command prompt (windows+r type "cmd" press "enter"). Navigate to *C:\Apache22\bin* and type httpd.exe then enter

@cocolote
cocolote / VIM-cheatsheet.md
Last active August 29, 2015 14:25
A reference with the basic commands for VIM

#Vim Basic Commands

###Modes i: change to insert mode to edit text v: change to visual mode to select text Esc: Normal mode to navigate through the text file

###Moves (Normal mode) h: move left | l: move right j: move up | k: move down