Commit d2ad080a889214d67fa091523f6e02c8eaa99b1f

Authored by Erickson Silva
1 parent b14f8587
Exists in master and in 2 other branches api, devel

Adicionado script de instalação do Aelius.

Instalação Aelius.tar.gz
No preview for this file type
ModuleTranslate.py
... ... @@ -1,16 +0,0 @@
1   -#!/usr/bin/python
2   -# -*- coding: utf-8 -*-
3   -
4   -import sys, os
5   -sys.path.append(os.getcwd()+"/tradutor/src/py")
6   -from Tradutor import *
7   -
8   -tradutor = Tradutor()
9   -
10   -def iniciar(x):
11   - try:
12   - text = x.decode("utf-8")
13   - except:
14   - text = x.decode("iso-8859-1")
15   -
16   - return tradutor.traduzir(text)
aelius-install.tar.gz 0 → 100644
No preview for this file type
aelius_install.sh 0 → 100644
... ... @@ -0,0 +1,36 @@
  1 +#!/bin/bash
  2 +
  3 +#Instalador do Tradutor Aelius
  4 +
  5 +cd ~/vlibras-core
  6 +
  7 +echo "\n# Extraindo...\n"
  8 +tar -xf aelius-install.tar.gz -C ~/.
  9 +
  10 +echo "# Instalando dependências...\n"
  11 +sudo apt-get install python-dev python-yaml python-numpy python-matplotlib
  12 +
  13 +cd ~/nltk-2.0.1rc1/
  14 +
  15 +sudo python setup.py install
  16 +
  17 +echo "\n# Finalizando...\n"
  18 +
  19 +# path to HunPos binaries
  20 +echo "\nPATH=\"${PATH}:$HOME/Applications/bin\"" >> ~/.bashrc
  21 +echo "export PATH\n" >> ~/.bashrc
  22 +
  23 +# path to Aelius and Translate package
  24 +echo "PYTHONPATH=\"${PYTHONPATH}:$HOME/Applications:$HOME/vlibras-core/tradutor/src/py\"" >> ~/.bashrc
  25 +echo "export PYTHONPATH\n" >> ~/.bashrc
  26 +
  27 +cd ..
  28 +
  29 +sudo mv usr-local-bin.tar.gz /usr/local/bin/
  30 +
  31 +cd /usr/local/bin/
  32 +
  33 +sudo tar -xf usr-local-bin.tar.gz
  34 +sudo rm usr-local-bin.tar.gz
  35 +
  36 +echo "### Instalação finalizada! \n## Execute o seguinte comando para concluir:\n\n$ source ~/.bashrc\n"
... ...
tradutor/src/py/ModuleTranslate.py 0 → 100644
... ... @@ -0,0 +1,14 @@
  1 +#!/usr/bin/python
  2 +# -*- coding: utf-8 -*-
  3 +
  4 +from Tradutor import *
  5 +
  6 +tradutor = Tradutor()
  7 +
  8 +def iniciar(x):
  9 + try:
  10 + text = x.decode("utf-8")
  11 + except:
  12 + text = x.decode("iso-8859-1")
  13 +
  14 + return tradutor.traduzir(text)
... ...