mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Remove all deprecated lists, not just 'yunohost'
This commit is contained in:
parent
5d9a62192f
commit
e2e9a7a033
1 changed files with 13 additions and 4 deletions
|
@ -1,5 +1,5 @@
|
||||||
from moulinette.utils.log import getActionLogger
|
from moulinette.utils.log import getActionLogger
|
||||||
from yunohost.app import app_fetchlist, app_removelist
|
from yunohost.app import app_fetchlist, app_removelist, _read_appslist_list
|
||||||
from yunohost.tools import Migration
|
from yunohost.tools import Migration
|
||||||
|
|
||||||
logger = getActionLogger('yunohost.migration')
|
logger = getActionLogger('yunohost.migration')
|
||||||
|
@ -10,12 +10,21 @@ class MyMigration(Migration):
|
||||||
|
|
||||||
def migrate(self):
|
def migrate(self):
|
||||||
|
|
||||||
# Remove official.json list
|
# Remove all the deprecated lists
|
||||||
app_removelist(name="yunohost")
|
lists_to_remove = [
|
||||||
|
"https://app.yunohost.org/official.json",
|
||||||
|
"https://app.yunohost.org/community.json",
|
||||||
|
"https://labriqueinter.net/apps/labriqueinternet.json"
|
||||||
|
]
|
||||||
|
|
||||||
|
appslists = _read_appslist_list()
|
||||||
|
for appslist, infos in appslists.items():
|
||||||
|
if infos["url"] in lists_to_remove:
|
||||||
|
app_removelist(name=appslist)
|
||||||
|
|
||||||
# Replace by apps.json list
|
# Replace by apps.json list
|
||||||
app_fetchlist(name="yunohost",
|
app_fetchlist(name="yunohost",
|
||||||
url="https://app.yunohost.org/apps.json")
|
url="https://app.yunohost.org/apps.json")
|
||||||
|
|
||||||
def backward(self):
|
def backward(self):
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue