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>