X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fseekat;a=blobdiff_plain;f=examples%2Fgistlog.php;h=6cdbe23faa070576085c585c34b79b013f19fe51;hp=723cc0c6f72d7fc1eb693c3e8545c42dc657c0ed;hb=HEAD;hpb=2451d97f1cb7b97e445b4dd839835b8673a4d0fc diff --git a/examples/gistlog.php b/examples/gistlog.php index 723cc0c..43d4ce1 100755 --- a/examples/gistlog.php +++ b/examples/gistlog.php @@ -1,11 +1,6 @@ #!/usr/bin/env php "token ".getenv("GITHUB_TOKEN") -]); +$api = include "examples.inc"; $api(function($api) { $gists = yield $api->users->m6w6->gists(); @@ -15,7 +10,7 @@ $api(function($api) { foreach ($gists as $gist) { foreach ($gist->files as $name => $file) { if ($name == "blog.md") { - $text = $file->as("raw")->raw();; + $text = $file->raw(); $head = $gist->description." ".$gist->created_at; echo "$head\n"; echo str_repeat("=", strlen($head))."\n\n";