{"id":18665371,"url":"https://github.com/robertklep/kodi","last_synced_at":"2025-08-12T02:04:58.383Z","repository":{"id":142182115,"uuid":"45185341","full_name":"robertklep/kodi","owner":"robertklep","description":"My Kodi scripts","archived":false,"fork":false,"pushed_at":"2017-02-21T19:08:05.000Z","size":2,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-31T00:57:37.888Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/robertklep.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-10-29T13:37:39.000Z","updated_at":"2017-02-21T19:08:06.000Z","dependencies_parsed_at":null,"dependency_job_id":"c7f17b8a-83d7-4e1f-84a5-71cf173db089","html_url":"https://github.com/robertklep/kodi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/robertklep/kodi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robertklep%2Fkodi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robertklep%2Fkodi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robertklep%2Fkodi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robertklep%2Fkodi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/robertklep","download_url":"https://codeload.github.com/robertklep/kodi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robertklep%2Fkodi/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269987123,"owners_count":24508176,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-12T02:00:09.011Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T08:27:24.485Z","updated_at":"2025-08-12T02:04:58.326Z","avatar_url":"https://github.com/robertklep.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Kodi scripts\n\nThis is a small selection of scripts for [Kodi](https://kodi.tv) that are useful to me, and perhaps to you as well.\n\n## Installation/Use\n\nThese aren't proper add-ons, so the process of using them is a bit elaborate.\n\nThe scripts are meant to be triggered by a key, which means creating your own custom `keymap.xml` (if you haven't got one already). [Here](http://kodi.wiki/view/Keymap) is more info on that process.\n\nMy general setup:\n\n``` \nKODIROOT\n    |\n    +-- userdata/\n    |      |\n    |      +-- keymaps/     \u003c- where keymap is stored\n    |      |\n    |      +-- scripts/     \u003c- where scripts are stored\n    |      |\n    |      ...\n    |\n    ...\n```\n\nFor example, I use the following keybinding for the `remove-video.py` script:\n\n``` xml\n\u003ckeymap\u003e\n  ...\n  \u003cvideolibrary\u003e\n    \u003ckeyboard\u003e\n      ...\n      \u003cd\u003exbmc.RunScript(special://userdata/scripts/remove-video.py)\u003c/d\u003e\n    \u003c/keyboard\u003e\n  \u003c/videolibrary\u003e\n\u003c/keymap\u003e\n```\n\nThis assigns the script to the `d` key when the video library is active. You can obviously use your own preferred key for any of the scripts.\n\n## The scripts\n\n### remove-video.py\n\nI find the operation of removing a TV show episode extremely tedious:\n\n* `c` to open the context menu\n* `Manage…`\n* `Remove from library`\n* _\"Are you sure you want to remove it from the library?\"_\n* _\"Are you sure you want to remove the file itself?\"_\n\nThis script will ask you a single question: _\"Are you sure?\"_. If you don't cancel that question (using `Esc`), it will remove the episode from both the library and the filesystem.\n\n### switch-directory.py\n\nIt regularly happens that Kodi shows an empty library folder even though there are files in the underlying filesystem folder (usually because the filenames aren't properly formatted, or the season/episode values don't match up with the scraper). This script will open the underlying filesystem folder so do you don't have to navigate there yourself.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frobertklep%2Fkodi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frobertklep%2Fkodi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frobertklep%2Fkodi/lists"}