Skip to content

Instantly share code, notes, and snippets.

View esayler's full-sized avatar

Eric Sayler esayler

View GitHub Profile
var Year = function(input) {
this.input = input;
};
Year.prototype.isLeap = function() {
if (this.input % 4 === 0) {
if (this.input % 100 === 0) {
if (this.input % 400 === 0) {
return true;

JavaScript Notes

  • sources: MDN, google/airbnb style guides

Comments

/// a one line comment

/* a mutli-

JavaScript Notes

  • sources: MDN, google/airbnb style guides

Comments

/// a one line comment

/* a mutli-

Atlassian Basic Git commands (Setting up a repo)

Getting Started

git init

  • creates a new Git repo
  • convert an existing project or initialize a new empty repo
  • creates a .git subdirectory in project root
  • .git contains metadata for the repo
@esayler
esayler / .gitignore_global
Last active August 1, 2016 16:45 — forked from octocat/.gitignore
Some common .gitignore configurations
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
(1..100).each do |x|
if x % 3 == 0
print "Crackle"
if x % 5 == 0
print "Pop"
end
print "\n"
elsif x % 5 == 0
puts "Pop"
else
@esayler
esayler / vim-notes.md
Last active September 17, 2015 21:12

vim notes

Note on notation

<C-p> = press the <Ctrl> and p keys at the same time dw = press the d key, then immediately the w key

etc

'tabstop' -- number of columns to expand a 'tab' character to onscreen

tmux notes

Commands

tmux new-session

tmux new -s SessionName

tmux new -s SessionName -n WindowName

#### COPY/PASTE ####
## vi keybindings in copy mode
setw -g mode-keys vi
# setup 'v' to begin selection in copy mode
bind-key -t vi-copy v begin-selection
bind-key -t vi-copy y copy-pipe "reattach-to-user-namespace pbcopy"