mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-19 20:24:49 +00:00
Fetch latest version automatically.
This commit is contained in:
parent
34f60dc4df
commit
7343667b50
14
index.html
14
index.html
|
|
@ -96,7 +96,7 @@ root: .
|
|||
<table class="borderless table">
|
||||
<tr>
|
||||
<td>Current version</td>
|
||||
<td><a href="http://wiki.torque3d.org/release:three-six-two">3.6.2</a></td>
|
||||
<td id="current-version">...</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Continuous integration</td>
|
||||
|
|
@ -219,5 +219,17 @@ $(document).ready(function() {
|
|||
}
|
||||
}
|
||||
});
|
||||
|
||||
$.get('http://api.github.com/repos/GarageGames/Torque3D/releases')
|
||||
.done(function(releases) {
|
||||
var latest = releases[0];
|
||||
$('#current-version').html($('<a/>')
|
||||
.attr('href', latest.html_url)
|
||||
.html(latest.name)
|
||||
);
|
||||
})
|
||||
.fail(function() {
|
||||
$('#curent-version').html('error');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
|
|
|||
Loading…
Reference in a new issue