HowTo "install" an AddOn from a git-repository

  Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
buhtz Offline
Junior Member
Posts: 14
Joined: Jul 2017
Reputation: 0
Post: #1
When I clone ("checkout") the sources of an AddOn (e.g. from GitLab or GitHub) how do I make Kodi aware that it is there?
How do you work on a AddOn code?

EDIT:
I found userdata/Datbases/Addons27.db which is a sqlite3 database. I think the table "installed" is relevant here.
So I see the workaround to install the AddOn from its official repo and then replace the addon-directory with the one I cloned with git.

Do you use other more elegant approaches? Wink
(This post was last modified: 2017-07-17 14:55 by buhtz.)
find quote
DarrenHill Offline
Team-Kodi Minion
Posts: 5,868
Joined: Oct 2014
Reputation: 136
Location: UK, except when I'm not.
Post: #2
In most cases from GitHub you can download the add-on as a zip file (rather than checking it out) and then point Kodi's Install from Zip option at wherever you saved the downloaded zip file (without unzipping it).

| Banned add-ons (wiki) | Forum rules (wiki) | First time user (wiki) | FAQs (wiki) | Troubleshooting (wiki) | Add-ons (wiki) | Free content (wiki) | Debug Log (wiki) | Free Movies/TV Shows
find quote
boogiepop Offline
Member
Posts: 68
Joined: Jan 2015
Reputation: 3
Post: #3
navigate to your addon folder which located in near the Userdata folder, with "addons" name. Userdata (wiki)

Download necessary packages in this directory. Best practice is to clone them:

git clone https://github.com/....git

İf thete is a dependency from official reo make sure you also axtract them also to the afdons folder from respective zipball.

Then launch kodi, kodi wil automatically find those addons and list them. under settings -> system -> addons

If you dont see them clear the addon*.db under /Database/addon*.db.

If addons are listed but grayed out it means that theya re disabled, go to addon info, click on it and select activate. Especially Kodi 17 Krypton does not automatically activate manually installed addons
find quote
Martijn Offline
Team Kodi
Posts: 17,006
Joined: Jul 2011
Reputation: 311
Location: Dawn of time
Post: #4
Clearing addon*.db is just plain stupid advice and should only be done is edge cases


The advice from darrenhill is the only correct advice unless you are a developer and know what you are doing

Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
(This post was last modified: 2017-07-17 23:32 by Martijn.)
find quote
buhtz Offline
Junior Member
Posts: 14
Joined: Jul 2017
Reputation: 0
Post: #5
(2017-07-17 23:30)Martijn Wrote:  The advice from darrenhill is the only correct advice unless you are a developer and know what you are doing
But working with a zip file makes no sense for a developer. I need the files from git (with the .git directory in them). This is not provided by a zip-file install.
find quote
boogiepop Offline
Member
Posts: 68
Joined: Jan 2015
Reputation: 3
Post: #6
deleting addon*.db is usefull only if you are working with several different versions of kodi (13+) in the same userdata folder, and for some reason your addon may be marked as broken or your directory structure is messed up and you want to change it etc afterwards.

deleting the db and let the app recreate helps to fresh restart. app creates dbs on each start anyways, i think martijn took that "like some flaw" in kodi db design and flamed but its not, it just is a trick in "dev-level".

installing zipballs from github is also ok, but only if the directory structure is correct as kodi in your git repo.

so in short i always work in userdata/addons/plugin.video.myaddon/.git to have flexibilitiy to source control and on-demand testing at the same time since it will always be installed.
find quote
buhtz Offline
Junior Member
Posts: 14
Joined: Jul 2017
Reputation: 0
Post: #7
(2017-07-18 09:56)boogiepop Wrote:  so in short i always work in userdata/addons/plugin.video.myaddon/.git to have flexibilitiy to source control and on-demand testing at the same time since it will always be installed.
This is exactly what I need.

I wasn't aware that Kodi find the manualy copied addon-folders but I have to explicte activate them. This is working. Thank you very much.
find quote