cd /usr/local/src
# download eclipse-php-2019-12-R-linux-gtk-x86_64.tar.gz from
# https://www.eclipse.org/downloads/
sudo tar xvfz eclipse-php-2019-12-R-linux-gtk-x86_64.tar.gz
Use Installer from e.g. https://ftp.snt.utwente.nl/pub/software/eclipse/oomph/epp/2020-09/R/eclipse-inst-jre-linux64.tar.gz and select Eclipse IDE for PHP Developers
cd /usr/local/src
wget https://ftp.snt.utwente.nl/pub/software/eclipse/oomph/epp/2020-09/R/eclipse-inst-jre-linux64.tar.gz
tar xvfz eclipse-inst-jre-linux64.tar.gz
cd eclipse-installer
./eclipse-inst
# select Eclipse IDE for PHP Developers
# Installation Folder: /usr/local/src/eclipse
~/Desktop$ cat eclipse.desktop
[Desktop Entry]
Type=Application
Terminal=false
Name=Eclipse
Exec=/usr/local/src/eclipse/eclipse
Comment=Eclipse 2019 Integrated development environment
Icon=/usr/local/src/eclipse/icon.xpm
StartupWMClass=Eclipse
see https://www.mediawiki.org/wiki/Manual:Running_MediaWiki_on_Debian_or_Ubuntu
sudo apt-get install apache2 mysql-server php php-mysql libapache2-mod-php php-xml php-mbstring
/usr/local/src$ sudo wget https://releases.wikimedia.org/mediawiki/1.33/mediawiki-1.33.2.tar.gz
wf@fur:/var/www/html$ sudo tar xvfz /usr/local/src/mediawiki-1.33.2.tar.gz
sudo ln -s mediawiki-1.33.2 wiki
/usr/local/src$ sudo wget wget https://releases.wikimedia.org/mediawiki/1.35/mediawiki-1.35.0.tar.gz
wf@fur:/var/www/html$ sudo tar xvfz /usr/local/src/mediawiki-1.35.0.tar.gz
rm wiki
wf@fur:/var/www/html$ ln -s mediawiki-1.35.0/ wiki
/usr/local/src$ sudo wget https://releases.wikimedia.org/mediawiki/1.33/mediawiki-1.33.2.tar.gz
wf@fur:/var/www/html$ sudo tar xvfz /usr/local/src/mediawiki-1.33.2.tar.gz
sudo ln -s mediawiki-1.33.2 wiki
/usr/local/src$ sudo wget wget https://releases.wikimedia.org/mediawiki/1.35/mediawiki-1.35.0.tar.gz
wf@fur:/var/www/html$ sudo tar xvfz /usr/local/src/mediawiki-1.35.0.tar.gz
rm wiki
wf@fur:/var/www/html$ ln -s mediawiki-1.35.0/ wiki
<?php
phpinfo();
sudo apt install php-pear
sudo pecl channel-update pecl.php.net
sudo pecl install xdebug
New Project "loop" add loop.php in include_path/loop folder
<?php
for ($i = 1; $i <= 10; $i++) {
echo $i;
}
Also need to configure debugger as asked for by Eclipse - use xdebug.
Also need to configure debugger as asked for by Eclipse - use xdebug.
make sure your user is part of group www-data
/var/www/html$ sudo chown www-data.www-data mediawiki-1.33.2
/var/www/html$ sudo chmod g+w mediawiki-1.33.2/
/var/www/html$ sudo chown -R www-data.www-data wiki
Create Eclipse project with "open project from existing source" using /var/www/html/wiki as the source folder
Enable composer in Project's properties There should be only some 20 errors and 60 warnings. Mostly the errors are XMLProblems and ComposerHook ComposerPack issues which are hopefully not relevant.
When first loading the project the DLTK indexing will take place and might take a while ...
When first loading the project the DLTK indexing will take place and might take a while ...
Personally I think break on first line isn't helpful because it triggers to often.
Set your breakpoints e.g. in the code e.g. of an extension.
Then click index.php and right click "Run Debug as PHP Web Application". You'll be asked for the URL to debug
After clicking "debug" the code will hopefully halt at one of your breakpoints and you can inspect what is going on.
e.g. S5SlideShow
{
"require": {
"wikimedia/at-ease": "*"
}
}
wget https://getcomposer.org/composer.phar
sudo php composer.phar update
/etc/php/7.2/mods-available$ cat xdebug.ini
zend_extension=xdebug.so
xdebug.remote_enable=On
sudo service apache2 restart
/etc/php/7.4/apache2/conf.d# cat 20-xdebug.ini
zend_extension=xdebug.so
xdebug.remote_enable=On
# only use when really debugging will slow down your apache quite a bit
# https://stackoverflow.com/a/19273025/1497139
#xdebug.remote_autostart=1
see https://askubuntu.com/questions/1002252/installing-configuring-zend-debugger-for-eclipse-pdt
cat 20-zend.ini zend_extension=/usr/local/src/ZendDebugger-linux-x86_64/php-7.0.x/ZendDebugger.so zend_debugger.allow_hosts=127.0.0.1,2.0.0.21 zend_debugger.expose_remotely=allowed_hosts zend_debugger.tunnel_min_port=1025 zend_debugger.tunnel_max_port=65534