In INSTALL.txt it says download textile from the textpattern project, and put the file in the same folder as textile.module, however in the code, there is a lot of extra code to use the Vars module (i assume for scanning for external libraries), and the default location to look is in path/to/modules/textile/includes.

I think a couple things need to be clarified in the installation instructions

1) Where are we supposed to get the best version of textile? eg, From the Textpattern download page, or from the Textile download page?

2) Where are we supposed to put the classTextile.php? Eg either in sites/all/libraries/textile/ or sites/all/modules/textile/includes? or sites/all/modules/textile?

Comments

jwilson3’s picture

Note both INSTALL.txt and README.txt have duplicate instructions for where to put the file... both say essentially "place the classTextile.php file into the same directory as textile.module."

Anonymous’s picture

Title: Installation instructions inconsistent with code » Update the installation instructions
Category: bug » task
Anonymous’s picture

Status: Active » Fixed

I slightly changed the installation instructions, and changed the README.txt file.
As far as I can see, the project page and the documentation files report to download the library file from the same website.

I created a different issue for the missing include directory (#1004862: The include directory is missing from the archive).

Thank you for your report.

jwilson3’s picture

Cheers, and on the contrary, thank YOU for your time and attention to my report!

jwilson3’s picture

If you are recommending the /sites/all/libraries strategy... I recommend following the model of the Installation instructions in the ApacheSolr README.txt that describe various suggestions on how to obtain the needed library file, and install it into your site. It also provides suggestions on how to get the right version using subversion, and how to use subversion externals, if your codebase is already using subversion.

http://drupalcode.org/viewvc/drupal/contributions/modules/apachesolr/REA...

Might be worth a look.

jwilson3’s picture

Hrm, This still is not completely fixed....

1) you changed the install url to admin/build/modules/include ????

http://drupalcode.org/viewvc/drupal/contributions/modules/textile/INSTAL...

2) you removed the entire set of logic for dynamically determining the path, as set by external libraries (Vars module), but didnt remove the dependency???

http://drupalcode.org/viewvc/drupal/contributions/modules/textile/textil...

3) Finally, I'll just point out the flaw in the inconsistency between install instructions and the code:

the INSTALL.txt for both d7 and d6 still say:

* The library should be availble via a link on the right in tar.gz or zip
  formats. Uncompress the download, and place the classTextile.php file
  into the same directory as textile.module.

But the code in d6 says:

function _textile_match_process($matches) {
  $path = drupal_get_path('module', 'textile') . '/include';
  if (empty($textile) && $path) {
    require_once './' . $path . '/classTextile.php'
    [...]
  }
}

And the code in d7 says:

function textile_library_path() {
  [...]
  $dirs = $vars->getLibraryPath('textile');
  $dirs[] = drupal_get_path('module', 'textile') . '/include';
  [...]
}

I propose the following set of changes....

D7 textile.module change from:

 $dirs[] = drupal_get_path('module', 'textile') . '/include';

to:

 $dirs[] = drupal_get_path('module', 'textile');

D6 textile.module change from:

$path = drupal_get_path('module', 'textile') . '/include';

to:

$path = drupal_get_path('module', 'textile');

Then, change both D7 and D6 INSTALL.txt to say the following...

Edited see attachment in the next comment, for a suggested format for the INSTALL.txt file.

Then, finally make the dependency on Vars module **OPTIONAL** by placing the logic for finding the path to the textile library AFTER the logic that checks the local directory.

jwilson3’s picture

Status: Fixed » Active
StatusFileSize
new3.44 KB

Hrm, the changes for INSTALL.txt in the previous comment got slightly flubbed by Drupal.org's CODE block formatting.

Uploading as an attachment.

Anonymous’s picture

Status: Active » Fixed

I changed the installation instructions as per your patch (they still report that the Textile library is looked in the include directory, if it is not present in other directories).

The Variables API library is required for compatibility with the Drupal 6 version of the module, where the module is necessary.

jwilson3’s picture

StatusFileSize
new3.32 KB

Its ok, but there are a couple minor changes that need to be made (word-wrap at 80 columns got messed up in a couple places and there is still one instance of the instructions that say to put the class file in the module folder (instead of in include).

Here is a patch..

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

I forgot to report I corrected the instruction file as reported in the next to the last comment.

jwilson3’s picture

Status: Closed (fixed) » Needs review

Please review my patch in #9, so it doesnt get lost. Thats work i did to fix the remaining issues.

Anonymous’s picture

Status: Needs review » Fixed

The changes have been already done.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.