Vous n'êtes pas identifié(e).
L'icône rouge permet de télécharger chaque page du wiki visitée au format PDF et la grise au format ODT →
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentes Révision précédente Prochaine révision | Révision précédente Prochaine révision Les deux révisions suivantes | ||
utilisateurs:hypathie:tutos:python-trucs-et-machins [29/12/2015 12:01] Hypathie [Installer Eric6 python] |
utilisateurs:hypathie:tutos:python-trucs-et-machins [30/12/2015 12:13] Hypathie [Installer Eric python IDE] |
||
---|---|---|---|
Ligne 44: | Ligne 44: | ||
<code retour>Python 3.4.2</code> | <code retour>Python 3.4.2</code> | ||
- | ===== Installer Eric6 python===== | ||
- | * On passe le système sous python3 | + | ====Changer de version de python avec update-alternatives ==== |
- | <code root>update-alternatives --install /usr/bin/python python /usr/bin/python2.7 1</code> | + | * Version actuelle pour tout le système : |
- | <code root>update-alternatives --install /usr/bin/python python /usr/bin/python3.4 2</code> | + | <code root>python --version</code> |
+ | |||
+ | * Voir où son les exécutable des version de python installées sur le système : | ||
+ | |||
+ | <code root>ls /usr/bin/python*</code> | ||
+ | <code retour>/usr/bin/python /usr/bin/python2.7 /usr/bin/python3.4 /usr/bin/python3m | ||
+ | /usr/bin/python2 /usr/bin/python3 /usr/bin/python3.4m | ||
+ | </code> | ||
+ | |||
+ | * Ajouter les version de python disponible à update-alternatives : | ||
<code root>update-alternatives --list python</code> | <code root>update-alternatives --list python</code> | ||
+ | <code retour>update-alternatives: erreur: pas d'alternatives pour python</code> | ||
- | <code root>python --version</code> | + | <code root>update-alternatives --install /usr/bin/python python /usr/bin/python2.7 1</code> |
+ | <code root>update-alternatives --install /usr/bin/python python /usr/bin/python3.4 2</code> | ||
- | <code root>Python 2.7.9</code> | + | * Pour changer de version de python : |
<code root>update-alternatives --config python</code> | <code root>update-alternatives --config python</code> | ||
- | |||
On choisit la version 3. | On choisit la version 3. | ||
- | <code root>python --version</code> | + | ===== Installer Eric python IDE===== |
+ | * Références : http://eric-ide.python-projects.org/eric-download.html | ||
+ | * Wiki d'utilisation de Eric IDE : http://ceg.developpez.com/tutoriels/pyqt/initiation-eric-et-qtdesigner/ | ||
- | <code root>Python 3.4.2</code> | + | ====Installation simple de Eric5 depuis les sources==== |
- | * On télécharge le script | + | 1) On vérifie que le système est sous python2 (voir ci-dessus) |
- | <code text script_installEric6> | + | 2) On installe depuis les sources |
- | #!/bin/sh | + | <code root>apt-get install eric</code> |
+ | (cela installe aussi le paquet ''eric-api-files'' | ||
- | apt-get install mercurial build-essential qt5-default qtbase5-dev qttools5-dev-tools libqt5scintilla2-11 python3-pyqt5.qtwebkit python3-pyqt5.qtsvg python3-pyqt5.qtsql libqt5webkit5-dev python3-pyqt5.qtwebkit python-qscintilla2 python3-pyqt4.qsci python3-pyqt4.qtsql | + | * Désinstaller Eric installé depuis les sources : |
+ | <code root>apt-get remove eric</code> | ||
- | mkdir temp | + | ====Installer Eric6 ==== |
- | cd temp | + | === Installer les dépendances depuis les dépôts=== |
- | apt-get source python3-pyqt5.qsci | + | <code root> |
+ | apt-get install python3-pyqt5 python3-pyqt5-dbg python3-pyqt4.qsci python3-pyqt5.qtx11extras python3-pyqt5.qtsql python3-pyqt5.qtsql-dbg python3-pyqt5.qtx11extras-dbg python3-pyqt5.qsci python3-pyqt5.qsci-dbg python-pyqt5.qtsvg python3-pyqt5.qtsvg-dbg python-pyqt5.qtwebkit python-pyqt5.qtwebkit-db python3-pyqt5.qtwebkit python3-pyqt5.qtwebkit-dbg | ||
+ | </code> | ||
- | cd qscintilla2-2.8.4+dfsg/Python/ | + | ===Installer eric6=== |
- | python3 configure.py --pyqt=PyQt5 \ #On indique qu'on souhaite utiliser pyqt5 | + | * On créer un dossier d'installation dans le répertoire courant de l'utilisateur : |
- | -q /usr/lib/x86_64-linux-gnu/qt5/bin/qmake \ #Chemin du compilateur qmake livré avec qt5 | + | |
- | -d /usr/lib/python3/dist-packages/PyQt5 # Chemin d'installation de PyQt5 | + | |
- | make | + | <code user>mkdir Eric6Install && cd Eric6Install</code> |
- | make install | + | * On télécharge Eric6 |
+ | <code user>wget http://heanet.dl.sourceforge.net/project/eric-ide/eric6/stable/6.1.0/eric6-6.1.0.tar.gz</code> | ||
- | cd ../.. | + | * On décompresse le dossier téléchargé : |
- | hg clone http://die-offenbachs.homelinux.org:48888/hg/eric | + | <code user>tar -zxvf eric6-6.1.0.tar.gz</code> |
- | cd eric | + | * On se déplace dans le dossier décompressé : |
- | python3 install.py | + | <code user>cd eric6-6.1.0/</code> |
- | rm -rf ~/Téléchargement/temp/ | + | * On lance l'installation de eric6 : |
- | exit | + | <code root>python3 install.py</code> |
- | </code> | + | |
+ | * Si toutes les dépendances ont bien été installée on a le retour : | ||
+ | <code>Checking dependencies | ||
+ | Python Version: 3.4.2 | ||
+ | Found PyQt5 | ||
+ | Found QScintilla2 | ||
+ | Found QtGui | ||
+ | Found QtNetwork | ||
+ | Found QtPrintSupport | ||
+ | Found QtSql | ||
+ | Found QtSvg | ||
+ | Found QtWebKit | ||
+ | Found QtWebKitWidgets | ||
+ | Found QtWidgets | ||
+ | Qt Version: 5.3.2 | ||
+ | sip Version: 4.16.4 | ||
+ | PyQt Version: 5.3.2 | ||
+ | QScintilla Version: 2.8.4 | ||
+ | All dependencies ok. | ||
+ | |||
+ | Cleaning up old installation ... | ||
+ | |||
+ | Creating configuration file ... | ||
+ | |||
+ | Compiling user interface files ... | ||
+ | |||
+ | Compiling source files ... | ||
+ | |||
+ | Installing eric6 ... | ||
+ | |||
+ | Installation complete.</code> | ||
+ | |||
+ | * On peut déjà lancer Eric6 en tant que root | ||
+ | <code root>eric6</code> | ||
+ | |||
+ | {{http://pix.toile-libre.org/upload/original/1451467749.png?00}} | ||
+ | |||
+ | ===Lancer eric6 en tant utilisateur=== | ||
+ | |||
+ | <code root>chmod a+w -R ~/.eric6</code> | ||
+ | |||
+ | <code user>eric6</code> | ||
+ | |||
+ | |||
+ | {{http://pix.toile-libre.org/upload/original/1451467749.png?00}} | ||
+ | |||
+ | Et voilà 8-) | ||
+ | |||
+ | ===Ajouter eric6 fr === | ||
+ | |||
+ | <code user>cd tmp/</code> | ||
+ | |||
+ | <code user>wget http://netcologne.dl.sourceforge.net/project/eric-ide/eric6/stable/6.1.0-RC1/eric6-i18n-fr-6.1.0-RC1.zip</code> | ||
+ | <code user>unzip eric6-i18n-fr-6.1.0-RC1.zip</code> | ||
+ | |||
+ | <code user>cd eric6-6.1.0-RC1/</code> | ||
+ | <code root>python3 install-i18n.py</code> | ||
+ | |||
+ | ===Installer Le plugin Django=== | ||
+ | |||
+ | * Depuis les références : http://eric-ide.python-projects.org/plugins6/repository.xml | ||
+ | On cherche l'url de django | ||
+ | <code><Plugin status="stable"><Name>Project, Django</Name><Short>Basic support for Django projects.</Short><Description> | ||
+ | This plug-in implements support for Django projects. It includes | ||
+ | API files for the various Django versions and a Django menu offering | ||
+ | various Django related actions from within eric5. | ||
+ | </Description><Url>http://eric-ide.python-projects.org/plugins6/stable/PluginProjectDjango.zip</Url><Author>Detlev Offenbach <detlev@die-offenbachs.de></Author><Version>4.0.2</Version><Filename>PluginProjectDjango-4_0_2.zip</Filename></Plugin></code> | ||
+ | |||
+ | * On copie l'url et on télécharge le plugin : | ||
+ | <code user>cd ~/tmp</code> | ||
+ | <code user>wget http://eric-ide.python-projects.org/plugins6/stable/PluginProjectDjango.zip</code> | ||
+ | |||
+ | * On ouvre eric6 | ||
+ | On clique sur l'onglet Plugins > Installation de plugins > puis ajouter \\ | ||
+ | On cherche dans ~/tmp/sonPlugin.zip\\ | ||
+ | On le sélectionne : | ||
+ | |||
+ | {{http://pix.toile-libre.org/upload/original/1451471865.png?900}} | ||
+ | |||
+ | Puis ''ouvrir'' > ''suivant'' > ''suivant'' > ''install'' | ||
+ | |||
+ | Eric6 redémarre et si tout est bon on peut créer un projet de type Django | ||
+ | |||
+ | |||
+ | |||
+ | Et voilà 8-) | ||
- | * On se place dans le dossier de réception | + | ===Désinstaller eric6=== |
- | <code user>mv ~/Téléchargements/script_installEric6 ~/Bureau/ && cd ~/Bureau/</code> | + | * On se déplace dans le fichier ''tmp/eric6-6.1.0'' |
+ | <code user>cd tmp/eric6-6.1.0/</code> | ||
- | * On donne les droits d'exécution | + | <code root>python3 uninstall.py</code> |
- | <code root>chmod +x script_installEric6</code> | + | |
- | * On lance le script | + | * Pour désinstaller les dépendances |
- | <code root>./script_installEric6</code> | + | <code root>apt-get remove python3-pyqt5 python3-pyqt5-dbg python3-pyqt4.qsci python3-pyqt5.qtx11extras python3-pyqt5.qtsql python3-pyqt5.qtsql-dbg python3-pyqt5.qtx11extras-dbg python3-pyqt5.qsci python3-pyqt5.qsci-dbg python-pyqt5.qtsvg python3-pyqt5.qtsvg-dbg python-pyqt5.qtwebkit python-pyqt5.qtwebkit-db python3-pyqt5.qtwebkit python3-pyqt5.qtwebkit-dbg</code> |
===== Utilisation ===== | ===== Utilisation ===== | ||