-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Change name to lektor-static-search. - Add reference to tipue and lunrjs in the Readme. - Delete references tpo tipue in the code and settings.
- Loading branch information
Showing
3 changed files
with
24 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
# lektor-tipue-search | ||
# lektor-static-search | ||
|
||
> This is under development | ||
This is a plugin for Lektor that adds support for [tipue search](http:https://www.tipue.com/search/) to projects. When enabled it can generate json files in the `tipue-search/` folder automatically when the server (or build process) is run with the `-f tipue` flag. | ||
This is a plugin for Lektor that adds support for static search to projects. When enabled it can generate json files in the `static-search/` folder automatically when the server (or build process) is run with the `-f static-search` flag. | ||
|
||
This json files can be used with js libraries like [Tipue search](http:https://www.tipue.com/search/) or [Lurn.js](http:https://lunrjs.com/). | ||
|
||
## Enabling the Plugin | ||
|
||
|
@@ -11,21 +13,21 @@ This is a plugin for Lektor that adds support for [tipue search](http:https://www.tipu | |
```bash | ||
mkdir papckages | ||
cd packages | ||
git clone [email protected]:rlaverde/lektor-tipue-search.git | ||
git clone [email protected]:rlaverde/lektor-static-search.git | ||
``` | ||
|
||
## Configurations | ||
|
||
There are some globals configurations: | ||
|
||
`configs/tipue-search.ini:` | ||
`configs/static-search.ini:` | ||
|
||
output_directory = tipue_search | ||
output_directory = static_search | ||
|
||
|
||
Also you should add an entry for any model that you want to be generated into de json file (it should start by `model`) | ||
|
||
`configs/tipue-search.ini:` | ||
`configs/static-search.ini:` | ||
|
||
```ini | ||
[model.blog-post] | ||
|
@@ -58,7 +60,7 @@ choices = some_tag, another_tag | |
|
||
and will generate a json file (for each alternative): | ||
|
||
`tipue_search/tipue_search_en.ini:` | ||
`static_search/static_search_en.ini:` | ||
|
||
```json | ||
[{"url": "/blog/example", | ||
|
@@ -72,5 +74,5 @@ and will generate a json file (for each alternative): | |
## Usage | ||
|
||
```bash | ||
lektor build -f tipue | ||
lektor build -f static-search | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
from setuptools import setup | ||
|
||
setup( | ||
name='lektor-tipue-search', | ||
name='lektor-static-search', | ||
version='0.1', | ||
author=u'Rafael Laverde,,,', | ||
author_email='[email protected]', | ||
license='MIT', | ||
py_modules=['lektor_tipue_search'], | ||
py_modules=['lektor_static_search'], | ||
entry_points={ | ||
'lektor.plugins': [ | ||
'tipue-search = lektor_tipue_search:TipueSearchPlugin', | ||
'static-search = lektor_static_search:StaticSearchPlugin', | ||
] | ||
} | ||
) |