Redmine #1487: adjusted directory structure and tweaked setup script

This commit is contained in:
Cyprian Laskowski 2021-03-25 15:43:16 +01:00
parent 695dd78379
commit 19e9eb6341
4 changed files with 16 additions and 24 deletions

7
.gitignore vendored
View File

@ -1,6 +1,3 @@
/venv /venv
/obeliks /lib
/data_admin /resources
/luscenje_struktur
/nova_slovnica
/xml_schemas

View File

@ -1,7 +0,0 @@
/classla
/dict.xml
/structures.xml
/structures.xsd
/inventory.xsd
/monolingual_dictionaries.xsd
/wani.py

View File

@ -1,13 +1,18 @@
#!/bin/bash #!/bin/bash
cd "$(dirname "$0")"
cd .. cd ..
mkdir lib resources
## get dependencies ## get dependencies
cd lib
git clone git@gitea.cjvt.si:redmine_projects/nova_slovnica.git git clone git@gitea.cjvt.si:redmine_projects/nova_slovnica.git
git clone git@gitea.cjvt.si:ozbolt/luscenje_struktur.git git clone git@gitea.cjvt.si:ozbolt/luscenje_struktur.git
git clone git@gitea.cjvt.si:generic/data_admin.git git clone git@gitea.cjvt.si:generic/data_admin.git
git clone git@gitea.cjvt.si:generic/xml_schemas.git git clone git@gitea.cjvt.si:generic/xml_schemas.git
scp -P 3022 proc1.cjvt.si:/net/nas/resources/miscellaneous/structures/structures.xml . scp -P 3022 proc1.cjvt.si:/net/nas/resources/miscellaneous/structures/structures.xml .
cd ..
## prepare python environment ## prepare python environment
python3 -m venv venv python3 -m venv venv
@ -17,19 +22,18 @@ pip install lxml
pip install psycopg2cffi pip install psycopg2cffi
pip install sqlalchemy pip install sqlalchemy
pip install classla pip install classla
python -c "import classla; classla.download('sl', type='standard_jos')" <<< $'Y\nresources/classla' python -c "import classla; classla.download('sl', type='standard_jos', dir='resources/classla')"
pip install obeliks pip install lib/nova_slovnica/python/package/
pip install nova_slovnica/python/package/ pip install lib/luscenje_struktur/
pip install luscenje_struktur/
pip install package/ pip install package/
deactivate deactivate
## put needed resources in place ## put needed resources in place
cd resources cd resources
ln -s ../luscenje_struktur/wani.py . ln -s ../lib/luscenje_struktur/wani.py .
ln -s ../nova_slovnica/resources/dict.xml . ln -s ../lib/nova_slovnica/resources/dict.xml .
ln -s ../data_admin/resources/structures.xsd . ln -s ../lib/data_admin/resources/structures.xsd .
ln -s ../xml_schemas/resources/schema/inventory.xsd . ln -s ../lib/xml_schemas/resources/schema/inventory.xsd .
ln -s ../xml_schemas/resources/schema/monolingual_dictionaries.xsd . ln -s ../lib/xml_schemas/resources/schema/monolingual_dictionaries.xsd .
mv ../structures.xml . mv ../lib/structures.xml .
cd .. cd ..

2
tmp/.gitignore vendored
View File

@ -1,2 +0,0 @@
*
!.gitignore