Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Get Tags of a GitHub Repository with links to Tarballs
#!/usr/bin/env php
$user = 'symfony';
$repo = 'symfony';
$url = ''.$user.'/'.$repo.'/tags';
$json = file_get_contents($url);
$tags = json_decode($json);
foreach($tags as $tag) {
echo $tag->name."\t".$tag->tarball_url."\n";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.