To toast:
- Make sure you have ImageMagick installed (
brew install imagemagick
) - Change line 7 of toast.rb to the repository name you're working with
- toast!
$ bundle install
$ ./get_token [user] [pass]
$ export GHUSER=[myuser]
(function() { | |
if ("-ms-user-select" in document.documentElement.style && navigator.userAgent.match(/IEMobile/)) { | |
var msViewportStyle = document.createElement("style"); | |
msViewportStyle.appendChild( | |
document.createTextNode("@-ms-viewport{width:auto!important}") | |
); | |
document.getElementsByTagName("head")[0].appendChild(msViewportStyle); | |
} | |
})(); |
To toast:
brew install imagemagick
)$ bundle install
$ ./get_token [user] [pass]
$ export GHUSER=[myuser]
// Public domain. | |
// Attribution welcome, but not required. -- Pyry Jahkola. | |
// What's the point in all this? To get the equivalent of CoffeeScript's | |
// (?.) operator into vanilla JavaScript. | |
// get(x, key1, key2, ...) -- Get the result of x[key1][key2]..., or undefined. | |
// Will short circuit if a key is not found. |
#include <SDKDDKVer.h> | |
#include <ShObjIdl.h> | |
#include <tchar.h> | |
int wmain(int argc, wchar_t* argv[]) | |
{ | |
const wchar_t* appId = L"WinningJS-test-runner_aw9cjjms6ptaw!App"; | |
CoInitialize(nullptr); | |
IApplicationActivationManager* aam = nullptr; |
This article has been given a more permanent home on my blog. Also, since it was first written, the development of the Promises/A+ specification has made the original emphasis on Promises/A seem somewhat outdated.
Promises are a software abstraction that makes working with asynchronous operations much more pleasant. In the most basic definition, your code will move from continuation-passing style:
getTweetsFor("domenic", function (err, results) {
// the rest of your code goes here.
@REM More info: | |
@REM http://caioproiete.net/en/get-access-to-the-programfileswindowsapps-folder-and-view-apps-source-code/ | |
@echo Backing up current folder permissions to a temporary file | |
@icacls "%ProgramFiles%\WindowsApps" /save "%TEMP%\WindowsApps.acl" /Q | |
@if ERRORLEVEL 1 goto rollback | |
@echo Assigning the ownership of the folder to the current logged user | |
@takeown /F "%ProgramFiles%\WindowsApps" | |
@if ERRORLEVEL 1 goto rollback |
[ | |
{ | |
"keys": ["ctrl+w"], | |
"command": "run_multiple", | |
"args": { | |
"commands": [ | |
{"command": "find_under_expand", "args": null, "context": "window"}, | |
{"command": "show_panel", "args": {"panel": "find"}, "context": "window"} | |
] | |
} |
These instructions work for the Raspberry Pi running Raspbian (hard float) and create a hardware optimized version of NodeJS for the Raspberry PI, (and include a working install and NPM!!!):
Install Raspbian - http://www.raspberrypi.org/downloads
Install the necessary dependecies:
sudo apt-get install git-core build-essential
(If you just installed git then you need to administer your git identity first, else adding the patches below will fail!!!)
<!DOCTYPE html> | |
<!-- File > New Project > Templates > JavaScript > Blank App; replace default.html with this --> | |
<html> | |
<head> | |
<meta charset="utf-8" /> | |
<title>App2</title> | |
<!-- WinJS references --> | |
<link href="//Microsoft.WinJS.1.0.RC/css/ui-dark.css" rel="stylesheet" /> | |
<script src="//Microsoft.WinJS.1.0.RC/js/base.js"></script> |
// add your variants of | |
a ? b : c | |
// in comments :) | |
// a is boolean | |
// b and c - any type | |
// lazy evaluation isnt important |