Blog
PHP Development with Eclipse
With PHPEclipse there is a decent plugin for PHP within
Eclipse available, although it isn't yet as feature rich as Eclipse for Java development it
is quite useable. In combination with the Subversion plugin
development becomes even easier.
For both PHPeclipse and Subclipse are well documented
install instructions available.
Note that there is also an official PHP-IDE from Eclipse which is developed together with Zend. This is however in a early development state and i haven't had time to take a closer look at it. In the longterm this is probably the solution to go with.
All in all i am quite happy with the development environment.
Marc
Subversion backend selection and authentication configuration
After a few db corruption and jurnal recovering with the Berkley DB backend i strongly advise you to use the filesystem based backend instead. I think it is by now the default but to be sure set it on the command line. By the way here is a comparison of the thow different backends. Personally i like the fact that if needed the repository data can be manipulated by standard tools.
svndadmin create --fs-type fsfs repoOnce the repository is created you can add your files.
svn import . file:///home/svn/repo -m "Initial commit."
Authentication with svnserve (from the docs)
The default svnserve setup provides anonymous read-only access. This means that you can use an svn:// Url to checkout and update, or use the repo-browser in TortoiseSVN to view the repository, but you won't be able to commit any changes.
To enable write access to a repository, you need to edit the conf/svnserve.conf file in your repository directory. This file controls the configuration of the svnserve daemon, and also contains useful documentation.
You can enable anonymous write access by simply setting:
[general]
anon-access = write
However, you will not know who has made changes to a repository, as the svn:author property will be empty. You will also be unable to control who makes changes to a repository. This is a somewhat risky setup!
One way to overcome this is to create a password database:
[general]
anon-access = none
auth-access = write
password-db = userfileWhere userfile is a file which exists in the same directory as svnserve.conf. This file can live elsewhere in your filesytem (useful for when you have multiple repositories which require the same access rights) and may be referenced using an absolute path, or a path relative to the conf directory. The userfile should have a structure of:
[users]
username = password
...
This example would deny all access for unauthenticated (anonymous) users, and give read-write access to users listed in userfile.
Just in case you do not already know, there is an ebook online which covers Subversion in depth.
Marc
Resizing loop back fileystems
I recently needed to resize an existing loop back fileystem which
was created with dd after some research i came up with the following which worked fine for me.
First you need to get the current image size preferably in megabytes this can be done with
# du -m loop-back-image.img
300 loop-back-image.imgIt says the size is 300mb, so here is how we can add another 100mb to it.
# dd if=/dev/zero of=loop-back-image.img bs=1M seek=300 count=100seek=300 means that dd will start at this point which is the end, and count=100 tells dd to add 100mb to that point, so we end up with a total size of 400mb. Run resize2fs on the enlarged 400mb image, it will resize the ext2 filesystem on it to fill the image.
# resize2fs loop-back-image.imgIf you want to reduce the loop back image size you first have to resize the filesystem on it.
# resize2fs loop-back-image.img 200MAfterwards you can run 'dd' on the 300mb image to reduce it to 200mb.
# dd if=/dev/zero of=loop-back-image.img bs=1M seek=200 count=0Again seek=200 says dd to start at 200mb and count=0 means that it should add nothing to that point so we end up with a total image size of 200mb.
Debian update and NO_PUBKEY found
To add the requested key do the following go to http://ftp-master.debian.org/ and download the archive signing key. Then add it to the system as shown below and go on normally.
apt-key add [file-of-key]Marc
Running Lotus Notes 6.5.x with WINE
I recently needed Lotus Notes 6.5.2 for business purposes, i knew that it kind of worded with WINE and so i gave it a try. Here are my tips for others who have to run Notes under a unix-like operating system.
1) Take a wine version which is known to work (20050725) newer
ones like 0.9 don't (at least i couldn't manage to make it work).
2) Install the notes client on a windows box
3) Adjust all settings on the windows box
- set the webrowser to notes
- set the sametime connection to manual
- configure proper TCP/IP settings and disable everything
else (NETBIOS)
4) Copy the notes directory over to the linux machine
5) Copy mfc42.dll and msvcp60.dll from C:\Windows\System32 to
~/.wine/drive_c/windows/system
6) Launch winecfg and set the windows version to Win98
7) Run Notes with wine "c:\program files\lotus\notes\nlnotes.exe"
Additional hints and help may be found in the comments in wine's appdb, the lotus notes ibm forum or over here.
Marc
