mirror of
https://codeberg.org/vlw/vlw.se.git
synced 2025-09-13 21:13:40 +02:00
This PR adds support for the latest major release of the [Vegvisir framework](https://vegvisir.vlw.se) Reviewed-on: https://codeberg.org/vlw/vlw.se/pulls/1 Co-authored-by: vlw <victor@vlw.se> Co-committed-by: vlw <victor@vlw.se>
17 lines
No EOL
538 B
PHP
17 lines
No EOL
538 B
PHP
<?php
|
|
|
|
/*
|
|
A pretty naive website version fetcher that assumes the latest git tag is the
|
|
version the website is currently displaying. The intent is that any live-master
|
|
of this website should always track the master branch and pull the latest HEAD
|
|
without any exceptions.
|
|
*/
|
|
|
|
// Get tags from local git folder
|
|
$dir = scandir(VV::root(".git/refs/tags"));
|
|
|
|
// Get current version number from latest tag
|
|
$version = end($dir);
|
|
|
|
?>
|
|
<a href="https://github.com/victorwesterlund/vlw.se/releases/<?= $version ?>"><?= $version ?></a>
|