This file contains hidden or 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
NewRepo(){ # NewRepo RepoName5 ~/RepoLocalPath5/ g or # NewRepo Repo1 ~/RepoLocal1/ b | |
mkdir $2 ; | |
cd $2 ; | |
echo $1 | pbcopy ; | |
echo "$1 $2 $3 un5t0ppab13" >> $3.txt ; # create new file$3 with text"$1$2$3" | |
if [ -a "g.txt" ] ; then | |
open 'https://github.com/new/' ; | |
elif [ -a "b.txt" ] ; then | |
open 'https://bitbucket.org/repo/create' ; | |
fi ; |
This file contains hidden or 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
// ==UserScript== | |
// @name remove_yt_a | |
// @description remove_yt_a | |
// @match *://*.youtube.com/* | |
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js | |
// @grant GM_addStyle | |
// @version 0.4 | |
// @author un5t0ppab13 | |
// ==/UserScript== |
This file contains hidden or 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
# MONKEY PATCHING: Reopen and Add to Any Class in Ruby, including Gems and core Ruby. | |
# CLASS: naively sum elements in an Array | |
[1,2,3,4].sum | |
# undefined method `sum' for [1, 2, 3, 4]:Array (NoMethodError) | |
class Array | |
def sum | |
sum = 0 | |
self.each do |e| | |
sum += e | |
end |
This file contains hidden or 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
#!/usr/bin/env bash | |
mkdir -p ~/.vimbundles | |
cd ~/.vimbundles | |
get_bundle() { | |
( | |
if [ -d "$2" ]; then | |
echo "Updating $1's $2" | |
cd "$2" | |
git pull --rebase |
This file contains hidden or 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
#!/usr/bin/env ruby | |
# reads in user provided parameter for function like ./readsFile2ReadIn.rb file2ReadIn | |
filename = ARGV.first | |
# when user forgets to provide parameter in function call like: ./readsFile2ReadIn4.rb | |
while !filename # if !filename # wont repeat and we want to repeat | |
print "file? \n" | |
file_again = $stdin.gets.chomp | |
print "Oh you want file: #{file_again} \n" # shows filename file2ReadIn which is not important... |
This file contains hidden or 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
#!/usr/bin/env ruby | |
# bst is O(log(n)) # the inverse is O(n^2)) | |
# Almost, the inverse of 2^n is log2(n) | |
# define Node with pointers left and right and data key|value pair | |
p Node = Struct.new(:data, :left, :right) | |
puts | |
# define tree having root and current | |
class Tree | |
attr_accessor :root |
This file contains hidden or 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
lng | lat | |
---|---|---|
-122.79231919578592 | 45.619783717220 | |
-122.79206328911766 | 45.621577190138 | |
-122.79173767947158 | 45.623871402354 | |
-122.79141980881165 | 45.625293820167 | |
-122.79139212632786 | 45.625382855427 | |
-122.79134413832539 | 45.625549974812 | |
-122.79127366998294 | 45.625789735902 | |
-122.79119623161218 | 45.626050556631 | |
-122.79111555750978 | 45.626328074953 |
This file contains hidden or 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
lng | lat | |
---|---|---|
-122.79231919578592 | 45.619783717220 | |
-122.79206328911766 | 45.621577190138 | |
-122.79173767947158 | 45.623871402354 | |
-122.79141980881165 | 45.625293820167 | |
-122.79139212632786 | 45.625382855427 | |
-122.79134413832539 | 45.625549974812 | |
-122.79127366998294 | 45.625789735902 | |
-122.79119623161218 | 45.626050556631 | |
-122.79111555750978 | 45.626328074953 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.