AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Natural Docs Custom Installer 1.1
Goto page 1, 2  Next
 
Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Thu Jun 21, 2007 3:26 pm    Post subject: Natural Docs Custom Installer 1.1 Reply with quote

 

_________________


Last edited by majkinetor on Mon Jan 25, 2010 2:46 pm; edited 43 times in total
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Wed Sep 05, 2007 2:09 pm    Post subject: Reply with quote

I found time to remove some unused Perl libraries.
Now, unpacked version is 7MB, packed 2MB.
_________________
Back to top
View user's profile Send private message
kiropes



Joined: 21 Mar 2007
Posts: 71

PostPosted: Mon Dec 17, 2007 10:58 am    Post subject: help Reply with quote

when I perform cmd mkdoc
I have this error:

Code:
"perl" it is not recognized as command inside or external,
 an executable program or a batch file.



I don't understand
Back to top
View user's profile Send private message
Andreone



Joined: 20 Jul 2007
Posts: 257
Location: Paris, France

PostPosted: Mon Dec 17, 2007 11:24 am    Post subject: Re: Natural Docs Custom Installer Reply with quote

majkinetor wrote:
Notes:
    - The installer updates your machine environment variables PATH and PERL5LIB. If you have perl already installed this installation will not spoil it.
So, you have to manually add to your PATH environment variable the directory where perl.exe is installed.
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Mon Dec 17, 2007 3:04 pm    Post subject: Reply with quote

Yes.
If Perl is already detected in PATH, nothing is added. If you have perl reference in the PATH and you don't have perl, that means you probably uninstalled it once and didn't remove perl fromt the PATH.

Keep in mind to restart your frontend app when you finish installing. For instance, if you install custom installer from Total Commander, TC will still have old env vars after installation is finished, so you have to restart TC to so it refreshes env vars. This can be pretty long chain, if you have non Microsfot launchers like DesktopX (in this case, both DesktopX and TC have to be restarted...)

Anyway, the custom installer currently doesn't work. It seems I removed too many libraries to reduce its size. I will probably fix it today.
_________________
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Mon Dec 17, 2007 4:38 pm    Post subject: Reply with quote

I fixed installer and now it works.

Also, there is a question now wether to add perl in PATH env var if it is found there, so that may fix initial problems with users that uninstalled Perl before using custom installer.
_________________
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Tue Dec 18, 2007 2:55 pm    Post subject: Reply with quote

This is AHK script for merging NDoc HTML parts into the single html file (so no more MHT docs)

mkdocs.ahk
Code:
root=_doc
fStyle=%root%\styles\main.css

FileRead, style, %fStyle%

loop, %root%\files\*.html
{
   FileRead, file, *t %A_LoopFileFullPath%
   StringReplace, file, file, <link rel="stylesheet" type="text/css" href="../styles/main.css">, <style>%style%</style>
   file := RegExReplace(file, "s)\Q<td class=MenuSection valign=top><!--START_ND_MENU\E.+?\Q<!--END_ND_MENU--></td>\E")

   StringReplace, fn, A_LoopFilename, -ahk
   FileDelete, %fn%
   FileAppend, %file%, %fn%
}


If you run this in scripts dir after running mkdoc, you will get single html file as documentation. You can also merge it with mkdoc.bat by adding at its end:
Code:
if "%1" == "s" (
   echo Merging html files ...
   mkdocs.ahk
   echo Done.
   echo.
)


Then instead mkdoc you can type mkdoc s to make documentation and merge files at the same time. You must put mkdocs.ahk at the same location as mkdoc.bat
_________________
Back to top
View user's profile Send private message
Rabiator



Joined: 17 Apr 2005
Posts: 289
Location: Sauerland

PostPosted: Tue Jun 17, 2008 9:18 am    Post subject: Re: Natural Docs Custom Installer Reply with quote

I installed the actual version of the installer, following the instructions of your first posting.

Now I get the following message, and I can't figure out the reason:
Code:
Unknown error
Compilation failed in require at C:\NaturalDocs\Perl\Lib/Cwd.pm line 643.
BEGIN failed--compilation aborted at C:\NaturalDocs\Perl\Lib/FindBin.pm line 281.
BEGIN failed--compilation aborted at C:\NaturalDocs\Perl\Lib/FindBin.pm line 281.
Compilation failed in require at NaturalDocs line 68.
BEGIN failed--compilation aborted at NaturalDocs line 68.

Before installing it I removed all path entries referring to perl.
The former package worked fine.
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Tue Jun 17, 2008 9:32 am    Post subject: Reply with quote

Ye, i screwed package a bit, didn't fix it yet. It seems I removed more libraries from Perl then NDoc uses it. It was a stupid thing to do anyway, just for those ppl who can't afor to have 40MB more wasted on perl...

Just download Perl and copy it in Ndoc\Perl folder to fix it.

Or wait for latest code with latest NDoc which is significantly upgraded and have support for images in help, superb Ajax search etc... I also added option to create single HTML file without ndoc project data by running "mkdoc s" (s as single html).
_________________
Back to top
View user's profile Send private message
Rabiator



Joined: 17 Apr 2005
Posts: 289
Location: Sauerland

PostPosted: Tue Jun 17, 2008 7:18 pm    Post subject: Reply with quote

Thanks.
With Perl 5.10 (17 MB) and Natural Docs 1.4 it works like a charm!
I like the ability to include images as shown in your Common Dialogs documentation Smile .
__________________________________________
Created with BBCodeWriter 7.0 - the one and only Very Happy
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Thu Jun 19, 2008 4:51 pm    Post subject: Reply with quote

I finally uploaded new version of custom installer. Its back to old good 12MB archive and now it can be used in directories with long names, you have "s" parameter to create single HTML and new Natural Docs that support images and Ajax search. Just put images in "\images" folder, or in root folder directly. To add them to code use "(see image.png)" Ndoc tag.
_________________
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Fri Jul 11, 2008 2:08 pm    Post subject: Reply with quote

Entirely new version.

I managed to compile Natural Docs into exe. Now you don't need to have Perl on your machine, and size on the disk droped from 46MB to 3MB.

I also made special extension *.ndoc that you can use to create any kind of documentation this way. It works the same as *.ahk files but it is there so you don't confuse your arbitrary documentation with ahk scripts.

Also, AHK is not required any more.
_________________
Back to top
View user's profile Send private message
aw1ace



Joined: 14 May 2008
Posts: 11

PostPosted: Sun Dec 07, 2008 8:46 pm    Post subject: Thanks! Reply with quote

This is Incredibly awesome and useful! It worked like a charm...
Thanks majkinetor!
_________________
-Ace
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Thu Jan 21, 2010 11:37 pm    Post subject: Reply with quote

*** version 1-1.c ***
+ Added AHK.css style and set to be default. Created by freakkk. You can use any other style by renaming them to Default.css.
+ Instalation improved.


You can see how new style looks here.
_________________
Back to top
View user's profile Send private message
majkinetor



Joined: 24 May 2006
Posts: 4511
Location: Belgrade

PostPosted: Mon Jan 25, 2010 2:01 pm    Post subject: Reply with quote

Sillent update:
- AHK style tweaks.
_________________
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group