kodi game repo incorrectly switched from the bundled version to
libretro repo which doesn't work as it uses git submodules.
Exclude it until that's fixed to avoid build breakage by incorrect
bumps.
Signed-off-by: Matthias Reichl <hias@horus.com>
Make sure we always return the latest tag in the branch and
only apply tag-suffix filtering if more than one tag exists.
This ensures we won't pick up an older (eg -Nexus) tag if newer
(eg -Matrix) tags are present - like it's currently the case with
game addons which only get "-Matrix" tags.
Signed-off-by: Matthias Reichl <hias@horus.com>
The game addons are currently being tagged with "-Matrix"
as suffix which doesn't match the "Nexus" branch of the binary
addons repo.
Allow overriding the tag suffix so we don't fall back to earlier
-Nexus tags of the addon.
usage eg: ./update_retroplayer-addons Nexus Matrix
Signed-off-by: Matthias Reichl <hias@horus.com>
Only accept standard github archive URLs and warn about other URLs
that aren't supported by the update script.
This avoids trashing PKG_VERSION with garbage, eg in libretro-mrboom
Signed-off-by: Matthias Reichl <hias@horus.com>
When environment variable GITHUB_API_TOKEN like in ${HOME}/.${DISTRO,,}/options
is assigned the script will fetch all data direct from Github instead
clone every single package.
game addons have (mostly?) switched from zip to tar.gz links,
add support for extracting the version info from these as well
to fix game addon updates.
Signed-off-by: Matthias Reichl <hias@horus.com>
Report which game addon packages are only present in LE but not in
the kodi game binary addon repo.
These packages are not automatically bumped by the script and should
either be removed from LE or added to the kodi game binary repo.
Signed-off-by: Matthias Reichl <hias@horus.com>
vfs.sacd has been deprecated in favour of audiodecoder.sacd and
removed from official kodi binary repo.
Add it to the exclude list until we finally remove the package so
the update script won't switch the version from tag to githash.
Signed-off-by: Matthias Reichl <hias@horus.com>
If no tag with the kodi branch name can be found, fall back to the
latest tag in the branch.
This fixes ambiguity if both a -Leia and a -Matrix tag point to the
same githash.
Signed-off-by: Matthias Reichl <hias@horus.com>
vfs.nfs has recently been removed from kodi's binary addon repo
and vfs.sacd is now included in LibreELEC
Signed-off-by: Matthias Reichl <hias@horus.com>
kodi-platform version is no longer managed in kodi's git tree and
needs to be updated manually, like p8-platform
Signed-off-by: Matthias Reichl <hias@horus.com>
The kodi-game binary addon repo now contains Leia and Matrix,
like the kodi binary addon repo, so make the branch name a
mandatory option.
Signed-off-by: Matthias Reichl <hias@horus.com>
Since Kodi Matrix hasn't branched yet and is still developed in
master the kodi branch name (master) and the branch name used in
addons (Matrix) doesn't match.
Allow to optionally specify the addon branch name on the command line,
eg "./update_binary-addons master Matrix".
This fixes visualization.pictureit bumps for master which picked
up the master branch of the addon instead of the Matrix branch.
Signed-off-by: Matthias Reichl <hias@horus.com>
Kodi binary and game addons always reference branches in the addon
repo. The only exception is the kodi-platform package which references
a githash.
This allows us to simplify remote repo fetch and tag / branch HEAD
resolving: we don't need named branches in the working copy but can
simply query remote branches or use a detached branch if we need the
actual contents.
With this change the same (out-of-tree) directory containing cloned
repos can be used to update both kodi Leia and master addon versions,
without needing another clone.
Also refactor the package update code, drop update_to_latest_tag from
common functions (it was only used by update_binary-addons,
update_retroplayer-addons needs slightly different logic) and use
update_pkg function. update_retroplayer-addons now also uses update_pkg
instead of duplicating nearly identical code.
Several variable names have been cleaned up to follow a common naming
pattern.
Signed-off-by: Matthias Reichl <hias@horus.com>
When updating versioned / tagged addons reset PKG_REV to 1.
When updating unversioned / untagged addons always bump PKG_REV
as we don't know if the version has been changed or not.
If the "-b/--bump-pkg-rev" option is used PKG_REV will be bumped
on all addons that weren't updated. Use this to ensure all addons
will have a newer version than before.
Signed-off-by: Matthias Reichl <hias@horus.com>
Use command line options to select PKG_REV bump and deleting
cloned git dis after update. git dirs are now kept by default,
deleting them has to be explicitly enabled via "-d".
Signed-off-by: Matthias Reichl <hias@horus.com>
As we are using tags, and the addon version should match the tag
version bumping PKG_REV on kodi game addon updates isn't needed.
As with update_binary-addons bumping PKG_REV may be wanted as
we are switching from HEAD to tags and can be enabled by setting
the PKG_BUMP_REV environment variable.
PKG_REV will also be bumped the script is run with "-f" as before.
Signed-off-by: Matthias Reichl <hias@horus.com>
Instead of bumping libretro cores to their current master version
use the githash from depends file in kodi game addon.
This ensures we ship the same libretro core versions as Kodi.
When a kodi game addon is bumped the libretro package is automatically
bumped, too.
If the script is invoked with the "-f" option all libretro packages
will be synced to the version specified in the kodi game addon.
Signed-off-by: Matthias Reichl <hias@horus.com>