Skip to content

Commit

Permalink
docs(DynamicModulesManager): Look for a enqueuer plugin installed in …
Browse files Browse the repository at this point in the history
…the same directory as enqueuer
  • Loading branch information
virgs committed May 31, 2019
1 parent 80fd20b commit e1c2a1a
Show file tree
Hide file tree
Showing 6 changed files with 1,332 additions and 1,320 deletions.
6 changes: 5 additions & 1 deletion README.md
Expand Up @@ -732,14 +732,18 @@ Tell enqueuer to use your plugin through configuration file this way:
Where plugin-folder and another-plugin-folder are the directories where the plugins are installed in.

##### implicitly
When enqueuer runs, it looks for modules in `.nqr` folder in the home directory, a.k.a. ~/ folder in linux distributions.
When enqueuer runs, it looks for modules in its same installation directory or in `.nqr` folder in the home directory, a.k.a. ~/ folder in linux distributions.
Therefore, if you run:

$ npm install --global enqueuer
$ mkdir ~/.nqr
$ cd ~/.nqr
$ npm install enqueuer-plugin-amqp
$ nqr -p amqp
Or

$ npm install --global enqueuer enqueuer-plugin-amqp
$ nqr -p amqp

You'll see that the `enqueuer-plugin-amqp` plugin will be loaded.
Every enqueuer compatible module gets implicitly loaded.
Expand Down
8 changes: 7 additions & 1 deletion docs/index.html
Expand Up @@ -1062,7 +1062,7 @@ <h5 id="configuration_file" style="padding-left: 16px">8.2.2 configuration file<

<h5 id="implicitly" style="padding-left: 16px">8.2.3 implicitly</h5>

<p>When enqueuer runs, it looks for modules in <code class="yaml">.nqr</code> folder in the home directory, a.k.a. ~/ folder in linux distributions.
<p>When enqueuer runs, it looks for modules in its same installation directory or in <code class="yaml">.nqr</code> folder in the home directory, a.k.a. ~/ folder in linux distributions.
Therefore, if you run:</p>

<pre><code class="yaml"><span class="dollar-sign">$</span> npm install --global enqueuer
Expand All @@ -1072,6 +1072,12 @@ <h5 id="implicitly" style="padding-left: 16px">8.2.3 implicitly</h5>
<span class="dollar-sign">$</span> nqr -p amqp
</code></pre>

<p>Or</p>

<pre><code class="yaml"><span class="dollar-sign">$</span> npm install --global enqueuer enqueuer-plugin-amqp
<span class="dollar-sign">$</span> nqr -p amqp
</code></pre>

<p>You'll see that the <code class="yaml">enqueuer-plugin-amqp</code> plugin will be loaded.
Every enqueuer compatible module gets implicitly loaded.
In order to be enqueuer compatible, a module has to have an <code class="yaml">entryPoint</code> exported function in its main file and, in its package.json file, it has to have either 'enqueuer' or 'nqr' as keywords.</p>
Expand Down
2 changes: 2 additions & 0 deletions enqueuer.ts
Expand Up @@ -26,6 +26,8 @@ export * from './src/configurations/store';
export * from './src/loggers/logger';

export * from './src/requisition-runners/requisition-parser';
export * from './src/requisition-runners/requisition-file-parser';
export * from './src/requisition-runners/requisition-file-pattern-parser';
export * from './src/requisition-runners/requisition-runner';

export * from './src/strings/id-generator';
Expand Down

0 comments on commit e1c2a1a

Please sign in to comment.