0
votes

I need programatically create new empty (or not) project. How can i do that? Then i use import-json to create components.

The documentation has import-project command, but

< project > names an existing project, into which the components should be imported.

1
Also created issueAndrey

1 Answers

0
votes

I can do that with weblate shell or ./manage.py shell

from weblate.trans.models import Project
project = Project.objects.create(
            name='Test',
            slug='test',
            web='https://weblate.org/'
)
project.save()

Also you can exec script from file

weblate shell < create_project.py