- Committed: Data is safely stored in your local db
- Modified: Data changed but not committed to db yet
- Staged: Changed data marked to go in next commit snapshot
| #!/bin/sh | |
| (( ${#} > 0 )) || { | |
| echo 'DISCLAIMER: USE THIS SCRIPT AT YOUR OWN RISK!' | |
| echo 'THE AUTHOR TAKES NO RESPONSIBILITY FOR THE RESULTS OF THIS SCRIPT.' | |
| echo "Disclaimer aside, this worked for the author, for what that's worth." | |
| echo 'Press Control-C to quit now.' | |
| read | |
| echo 'Re-running the script with sudo.' | |
| echo 'You may be prompted for a password.' | |
| sudo ${0} sudo |
| // parseUri 1.2.2 | |
| // (c) Steven Levithan <stevenlevithan.com> | |
| // MIT License | |
| // via: http://blog.stevenlevithan.com/archives/parseuri | |
| function parseUri (str) { | |
| var o = parseUri.options, | |
| m = o.parser[o.strictMode ? "strict" : "loose"].exec(str), | |
| uri = {}, | |
| i = 14; |
| function downloadCapture(forceDownload) | |
| { | |
| var canvas = document.getElementById("canvas"); | |
| var image = canvas.toDataURL("image/png"); | |
| if (forceDownload) | |
| image = image.replace("data:image/png;base64", "data:application/octet-stream;base64"); | |
| window.open(image, "_blank"); | |
| } |
| {% assign myArray = "1,2,3" | split: "," %} |
| /* | |
| Bookmarklet Ready Code: | |
| javascript:(function()%7Bdocument.body.spellcheck%3Dfalse%3Bif(!document.getElementById(%22__editing__%22))%7Bvar%20__editing__div%3Ddocument.createElement('div')%3B__editing__div.setAttribute('style'%2C%20'width%3A100%25%3B%20height%3A10px%3B%20background%3A%20red%3B%20position%3A%20fixed%3B%20top%3A%200px%3B%20left%3A%200px%3B%20z-index%3A%201000000%3B')%3B__editing__div.setAttribute('id'%2C%20'__editing__')%3Bvar%20__body%3D%20document.getElementsByTagName('body')%5B0%5D%3B__body.appendChild(__editing__div)%3B%7Dif(document.body.contentEditable!%3D'true')%7Bdocument.body.contentEditable%3D'true'%3Bdocument.designMode%3D'on'%3Bdocument.getElementById(%22__editing__%22).style.display%20%3D%20'block'%3B%7Delse%7Bdocument.body.contentEditable%3D'false'%3Bdocument.designMode%3D'off'%3Bdocument.getElementById(%22__editing__%22).style.display%20%3D%20'none'%3B%7D%7D)() | |
| */ | |
| document.body.spellcheck=false; | |
| if(!document.getElementById("__editing__")) | |
| { |
Tumblr command for Backtick. A Backtick command consists of some executable JavaScript and a bit of metadata in JSON.
Here are the required steps to create a command:
-
Create a new Gist with a
command.jsandcommand.jsonfile, or simply fork this one. -
Write your JavaScript in
command.js. This will be injected into and executed on the page the user is currently on when they run it.
'Delicious' command for Backtick. A Backtick command consists of some executable JavaScript and a bit of metadata in JSON.
Here are the required steps to create a command:
-
Create a new Gist with a
command.jsandcommand.jsonfile, or simply fork this one. -
Write your JavaScript in
command.js. This will be injected into and executed on the page the user is currently on when they run it.
| /* | |
| Bookmarklet Ready Code: | |
| javascript:(function(){var h=document.location.href;var regex=/http(s?)\:\/\/developers\.facebook\.com\/x\/apps\/(\w*)/;var appid=h.match(regex)[2];var u='https://www.facebook.com/dialog/pagetab?redirect_uri=http://www.facebook.com/&app_id='+appid;window.location.href=u;})(); | |
| */ | |
| var h = document.location.href; | |
| var regex = /http(s?)\:\/\/developers\.facebook\.com\/x\/apps\/(\w*)/; | |
| var appid = h.match(regex)[2]; |