<commit_before>= DoctorPepper README
jnorthr <<EMAIL>>
V1.1, Updated 25 Mar.2017: DoctorPepper Notes
:sectanchors:
:sectlinks:
:icons: font
:imagesdir: ./images

== Status

*Travis C/I* Project Health -
image:https://img.shields.io/travis/jnorthr/DoctorPepper.svg[Build Status (Travis CI), link=https://travis-ci.org/jnorthr/DoctorPepper]  image:https://img.shields.io/hexpm/l/plug.svg[Apache License, link=https://github.com/jnorthr/DoctorPepper/blob/master/LICENSE]

''''

== Purpose

This is an open-source tool to continuously translate any asciidoctor file that is changed within a defined folder.

image::divider3.png[align=center, title-align=center]

''''

== DropBox or Google Drive Enabled ?

This trick works nicely if you have a shared drive service like *Dropbox*, or *Google Drive* etc. and all your internal systems use the same *Dropbox*,etc. account.

I have six systems in my place. All of them hooked to same remote drive account. This way i can work on any of my internal systems and
still use/keep documentation and code safely and visibly on *all* my systems.

On one of my least-used systems, did the following:

.Gradle Continuous Doctor Translation
[source,bash]
----
cd ~/Dropbox
git clone https://github.com/jnorthr/DoctorPepper.git
cd ~/Dropbox/DoctorPepper
gradlew -t asciidoctor
----

The *-t* option keeps gradle running in continuous mode so now any changes i make to any asciidoctor files are near-instantly
translated for me.


NOTE: If you don't have a *git* client https://git-scm.com/downloads[click here to install one]

''''

== Update from A Different System

Went to a second system in my place. Updated this *Dropbox/DoctorPepper/src/docs/asciidoc/sample.adoc* file with:

More stuff here. Did this `sample.html` update from another machine show up on my *Dropbox* account?

Will a new *sample.html* show up on this machine too ?

''''

IMPORTANT: NO ! Why not ? Because screen saver on my gradle system put it to sleep !

''''

== Don't Allow Sleeping on The Job

If the server or desktop running your `gradlew -t asciidoctor` continuous process has it's screen saver
turned on, then you will only have continuous doctor translation while it does not sleep.

With full-time running, my asciidoctor translation process will nicely convert any/every change i make to my *.adoc*,etc.
 documents within the *src/docs/asciidoc* folder. 

''''

== Goal

What does this achieve ? Well anywhere on any of my six systems, i can modify my documentation and the _kind-of_
remote server will produce a new `*.html* set of results. Then i can have one or several browsers viewing the
results of files i'm editing, say in folder *DoctorPepper/build/docs* for my revised *sample.html*.

While doing this page, i had my text editor open, fixed some spelling mistakes and only did an editor save, like *Ctrl-S*
and toggled over to my window with the browser open to this *sample.html* page and did a browser re-fresh! *Bang!*

NOTE: Near-instant Translation

Then i only click browser refresh to see the new view and this saves me the bother of copying 
everything up to my CloudFoundry target. *Nice ;-)*

TIP: Just copying new *.adoc* files into *src/docs/asciidoc* will appear in the output folder too !

''''

== Table of Contents / Summary Page

While working on this tool, decided to write some groovy to generate an asciidoctor file named *toc.adoc* and
this is written into the same folder that the asciidoctor task is watching. The next time this task runs, the *toc.adoc*
is magically turned into an *toc.html* page with links to every `*.html` within the watched folder or sub-folders.

IMPORTANT: Surprise !

Was *surprised* when i accidentally ran *groovydoc* task to produce some API doc.s for my `Walker.groovy` code, and low-and-behold<commit_msg>fix spelling<commit_after>= DoctorPepper README
jnorthr <<EMAIL>>
V1.1, Updated 25 Mar.2017: DoctorPepper Notes
:sectanchors:
:sectlinks:
:icons: font
:imagesdir: ./images

== Status

*Travis C/I* Project Health -
image:https://img.shields.io/travis/jnorthr/DoctorPepper.svg[Build Status (Travis CI), link=https://travis-ci.org/jnorthr/DoctorPepper]  image:https://img.shields.io/hexpm/l/plug.svg[Apache License, link=https://github.com/jnorthr/DoctorPepper/blob/master/LICENSE]

''''

== Purpose

This is an open-source tool to continuously translate any asciidoctor file that is changed within a defined folder.

image::divider3.png[align=center, title-align=center]

''''

== DropBox or Google Drive Enabled ?

This trick works nicely if you have a shared drive service like *Dropbox*, or *Google Drive* etc. and all your internal systems use the same *Dropbox*,etc. account.

I have six systems in my place. All of them hooked to same remote drive account. This way i can work on any of my internal systems and still use/keep documentation and code safely and visibly on *all* my systems.

On one of my least-used systems, did the following:

.Gradle Continuous Doctor Translation
[source,bash]
----
cd ~/Dropbox
git clone https://github.com/jnorthr/DoctorPepper.git
cd ~/Dropbox/DoctorPepper
gradlew -t asciidoctor
----

The *-t* option keeps gradle running in continuous mode so now any changes i make to any asciidoctor files are near-instantly
translated for me.


NOTE: If you don't have a *git* client https://git-scm.com/downloads[click here to install one]

''''

== Update from A Different System

Went to a second system in my place. Updated this *Dropbox/DoctorPepper/src/docs/asciidoc/sample.adoc* file with:

More stuff here. Did this `sample.html` update from another machine show up on my *Dropbox* account?

Will a new *sample.html* show up on this machine too ?

''''

IMPORTANT: NO ! Why not ? Because screen saver on my gradle system put it to sleep !

''''

== Don't Allow Sleeping on The Job

If the server or desktop running your `gradlew -t asciidoctor` continuous process has it's screen saver
turned on, then you will only have continuous doctor translation while it does not sleep.

With full-time running, my asciidoctor translation process will nicely convert any/every change i make to my *.adoc*,etc.
 documents within the *src/docs/asciidoc* folder within one or two seconds.

''''

== Goal

What does this achieve ? Well anywhere on any of my six systems, i can modify my documentation and the _kind-of_
remote server will produce a new `*.html* set of results. Then i can have one or several browsers viewing the
results of files i'm editing, say in folder *DoctorPepper/build/docs* for my revised *sample.html*.

While doing this page, i had my text editor open, fixed some spelling mistakes and only did an editor save, like *Ctrl-S*
and toggled over to my window with the browser open to this *sample.html* page and did a browser re-fresh! *Bang!*

NOTE: Near-instant Translation

Then i only click browser refresh to see the new view and this saves me the bother of copying 
everything up to my CloudFoundry target. *Nice ;-)*

TIP: Just copying new *.adoc* files into *src/docs/asciidoc* will appear in the output folder too !

''''

== Table of Contents / Summary Page

While working on this tool, decided to write some groovy to generate an asciidoctor file named *toc.adoc* and
this is written into the same folder that the asciidoctor task is watching. The next time this task runs, the *toc.adoc*
is magically turned into an *toc.html* page with links to every `*.html` within the watched folder or sub-folders.

IMPORTANT: Surprise !

Was *surprised* when i accidentally ran *groovydoc* task to produce some API doc.s for my `Walker.groovy` code, and low-and-behold
{'fraction_non_alphanumeric': 0.08260983951591687, 'fraction_numerical': 0.0023677979479084454, 'mean_word_length': 4.294568245125348, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 12, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4346663', 'n_tokens_mistral': 2311, 'n_tokens_neox': 2205, 'n_words': 1055}