SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Enthusiast Kymira's Avatar
    Join Date
    Sep 2002
    Posts
    88
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    PHP "diff" implementation?

    I am looking for a PHP implementation of the UNIX "diff" utility. I found an implementation of one as part of the phpwiki project, but it is licensed under the GPL. I want to use the diff utility in a propriertary product, so I would need something that is LGPL'ed. Any help?

    I have searched the PHP forums, but did not find anything.
    Last edited by Kymira; Mar 18, 2003 at 18:45.

  2. #2
    SitePoint Wizard gold trophysilver trophy
    Join Date
    Nov 2000
    Location
    Switzerland
    Posts
    2,479
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Tricky - pretty narrow requirements with the license and all - personally never heard of diff implemented in PHP. If you don't get any luck here, try the phpDocumentor crew ( http://phpdocu.sourceforge.net/ ) - these guys are using the PHP tokenizer extension to generate Javadoc style output from PHP. In theory I guess you could use the same trick for an efficient diff tool - may be they'd know of one or could tell you more.

  3. #3
    SitePoint Enthusiast Kymira's Avatar
    Join Date
    Sep 2002
    Posts
    88
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by HarryF
    Tricky - pretty narrow requirements with the license and all - personally never heard of diff implemented in PHP. If you don't get any luck here, try the phpDocumentor crew ( http://phpdocu.sourceforge.net/ ) - these guys are using the PHP tokenizer extension to generate Javadoc style output from PHP. In theory I guess you could use the same trick for an efficient diff tool - may be they'd know of one or could tell you more.
    Well, I actually did find an implementation in PHP. I said in the first post that the phpWiki project has a library file that implements diff in PHP. The only problem is that it's GPL'ed... Oh well. I'll have to take a look at the GNU diff implementation and use that as a guide to write a PHP version.

    If there is anyone else out there who knows of a BSD/LGPL diiff implementation in PHP, I appreciate a heads up.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •