Skip to content

Instantly share code, notes, and snippets.

View markstachowski's full-sized avatar

Mark Stachowski markstachowski

View GitHub Profile

Rails naming conventions

General Ruby conventions

Class names are CamelCase.

Methods and variables are snake_case.

Methods with a ? suffix will return a boolean.

@markstachowski
markstachowski / ffmpeg-install.sh
Created March 7, 2018 02:36 — forked from midwire/ffmpeg-install.sh
Install FFMPEG on OS X with HomeBrew and all libs and support
brew install ffmpeg \
--with-dcadec \
--with-faac \
--with-fdk-aac \
--with-ffplay \
--with-fontconfig \
--with-freetype \
--with-frei0r \
--with-libass \
--with-libbluray \
@markstachowski
markstachowski / instructions.md
Created February 11, 2018 07:54 — forked from tpai/instructions.md
use both Tor and Privoxy with Mac OSX

1. install

brew install tor
brew install privoxy

2. copy and modify config file

Google Query String Parameters

Google Search

Query:

http://...

| URL Parameter | Accepted Values | Description |

1. Select a web site.

use wget to mirror www.mit.edu

Imgur

the directory hierarchy of the site.

@markstachowski
markstachowski / Web Components Resources.md
Created November 12, 2017 22:16 — forked from ebidel/Web Components Resources.md
List of resources related to Web Components
@markstachowski
markstachowski / readme.markdown
Created November 12, 2017 22:15 — forked from paulherron/readme.markdown
Creating a 'Share on Google+' URL with this Dubious Clusterhack

#Creating a 'Share on Google+' URL with this Dubious Clusterhack

Disclaimer: This is a ridiculous set of hacks. I had fun messing about with this and wanted to share it, but I wouldn't recommend using it for anything important. It may stop working at any time.
tl;dr: Google doesn't support sharing arbitrary URLs via a simple share link, but you can work around it by doing a redirect via Google, like so: https://plus.google.com/share?url=http%3A%2F%2Fgoogle.com%2Fsearch%3FbtnI%3D1%26q%3Dshowstudio%26sourceid%3Dnavclient

Most social sites let you share a link by visiting a special URL, for example:

Twitter. http://twitter.com/home?status=http://showstudio.com
Facebook. http://www.facebook.com/sharer.php?u=http://showstudio.com

Google Apps Script Document Utilities

  • getAllLinks.js

  • getAllLinks(element) - returns array of all UrlLinks in Document

  • findAndReplaceLinks(searchPattern,replacement) - changes all matching links in Document

  • changeCase.js - Document add-in, provides case-change operations in the add-in Menu.

  • onOpen - installs "Change Case" menu

  • _changeCase - worker function to locate selected text and change text case. Case conversion is managed via callback to a function that accepts a string as a parameter and returns the converted string.

  • helper functions for five cases

@markstachowski
markstachowski / google-fu-tips.md
Created November 12, 2017 22:12 — forked from dannguyen/google-fu-tips.md
Drafting a list of general search tips
@markstachowski
markstachowski / google-search-operator
Created November 12, 2017 22:06 — forked from dnsang/google-search-operator
Google Useful Command
# some common and useful google search tips
# for ref: http://www.google.com/advanced_search
###### tips #####
define hello >> to looking for definition of hello
###### Content Search & Operator ########
"hello world" >> to search for exact match of hello world
hello + world >> to search for hello and word eg: hello to my world
hello -world >> to search for hello, exclude word eg: hello to my house
hello * world >> to search fuzzy for hello *** world
~hello >> to search similar for hello eg: hi, hey