Simple nodejs script to convert timeline from twitter (https://dev.twitter.com) to twtxt (https://github.com/buckket/twtxt) format.
$ npm install twitter moment
$ convert.js > ~/twtxt.txt
Simple nodejs script to convert timeline from twitter (https://dev.twitter.com) to twtxt (https://github.com/buckket/twtxt) format.
$ npm install twitter moment
$ convert.js > ~/twtxt.txt
@mixin respond-to($medias...) { | |
$breakpoints-length: length($respond-to-breakpoints); | |
@each $media in $medias { | |
$had-a-hit: false; | |
@for $i from 1 through $breakpoints-length { | |
$breakpoint: nth($respond-to-breakpoints, $i); | |
@if $media == nth($breakpoint, 1) { | |
$definition: nth($breakpoint, 2); |
define bash_exec ( | |
$command = $name, | |
$user, | |
$creates = undef, | |
$cwd = undef, | |
$environment = undef, | |
$group = undef, | |
$logoutput = undef, | |
$onlyif = undef, | |
$path = undef, |
application/vnd.collection+json
{ "collection" :
{
"version" : "1.0",
"href" : "http://example.org/friends/",
"links" : [
{"rel" : "feed", "href" : "http://example.org/friends/rss"}
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
config.vm.box = "precise64" |
<?php | |
function createFoo() | |
{ | |
$pdo = new PDO(/*...*/); | |
$maxTryCount = 3; | |
$tryCount = $maxTryCount; | |
while ($tryCount > 0) | |
{ |
Hint: This is heavily based on https://gist.github.com/3428555.
Additional information about your API call. Try to use verbs that match both request type (fetching vs modifying) and plurality (one vs multiple).
The request type and the URL Structure (path only, no root url). METHOD may be GET
| POST
| DELETE
| PUT
.
Index: agavi/src/request/AgaviWebRequest.class.php | |
=================================================================== | |
--- agavi/src/request/AgaviWebRequest.class.php (revision 4918) | |
+++ agavi/src/request/AgaviWebRequest.class.php (working copy) | |
@@ -353,7 +353,16 @@ | |
// map REQUEST_METHOD value to a method name, or fall back to the default in $sourceDefaults. | |
// if someone set a static value as default for a source that does not have a mapping, then he's really asking for it, and thus out of luck | |
$this->setMethod($this->getParameter(sprintf('method_names[%s]', $REQUEST_METHOD), $this->getParameter(sprintf('method_names[%s]', $sourceDefaults['REQUEST_METHOD'])))); | |
- | |
+ |
Index: agavi/request/AgaviWebRequest.class.php | |
=================================================================== | |
--- agavi/request/AgaviWebRequest.class.php (revision 1086) | |
+++ agavi/request/AgaviWebRequest.class.php (working copy) | |
@@ -343,6 +343,7 @@ | |
$methods = array_merge(array( | |
'GET' => 'read', | |
'POST' => 'write', | |
+ 'PATCH' => 'patch', | |
'PUT' => 'create', |