Skip to content

Commit

Permalink
Add changelog and update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
mattico committed Jun 2, 2022
1 parent 087d9ff commit d84113c
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 4 deletions.
33 changes: 33 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

## [3.0.0] - 2022-06-01
### Added
- Language support for Arabic ([#40](https:/mattico/elasticlunr-rs/pull/40])).
- Add the `Language` trait to make it easier to implement languages outside the crate.
- Add `IndexBuilder::add_field_with_tokenizer` to specify the tokenizer for a field.

### Changed
- Update to 2018 edition, and bump MSRV to 1.54.0.
- Change benchmarks to use Criterion.
- Remove dependency on lazy_static.
- Update dependencies.
- Use Unicode character classes for trimmer.
- `IndexBuilder` functions which add fields will now panic if the same field is added multiple times.
- Fix `IndexBuilder` not respecting field insertion order.

### Removed
- Remove the `default` feature. You now need to opt-in to the `languages` feature.
- Remove the deprecated function `Pipeline::for_language`.
- Remove the `pipeline::tokenize*` functions, which are now implemented as part of the `Language` trait.
- Remove `Index::add_doc_with_tokenizer(s)`, replaced by `IndexBuilder::add_field_with_tokenizer`.
- Remove the `Language` enum. Use the `Language` trait implementations in the `lang` modules, and the free functions `lang::from_name`, `lang::from_code`, and `lang::languages`.


[Unreleased]: https:/mattico/elasticlunr-rs/compare/v3.0.0...HEAD
[3.0.0]: https:/mattico/elasticlunr-rs/compare/v2.3.14...v3.0.0
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,12 @@ file.write_all(index.to_json_pretty().as_bytes());

1.54.0

## Languages

This library includes optional support for non-English languages, see the features in `Cargo.toml`. Like in the JavaScript
version, the language support is designed to be compatible with the [lunr-languages plugins][lunr-languages]. Some
languages use a modified version, which is included in the `js` directory of the repository.

## License

This repository is offered under the terms of the
Expand All @@ -45,5 +51,8 @@ used under license. See LICENSE-JS for details.
Includes stop word lists ported from [stopwords-filter][swft] Copyright (C) 2012
David J. Brenes, used under license. See LICENSE-WORDS for details.

Bundled javascript code in the repository (not included in the cargo package) may have other licenses.

[lunr-languages]: https:/MihaiValentin/lunr-languages
[eljs]: https:/weixsong/elasticlunr.js
[swft]: https:/brenes/stopwords-filter
[swft]: https:/brenes/stopwords-filter
2 changes: 0 additions & 2 deletions js/lunr.ar.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
* Copyright 2018, Dalia Al-Shahrabi
* http://www.mozilla.org/MPL/
*/
/*!
*/

/**
* export the module via AMD, CommonJS or as a browser global
Expand Down
2 changes: 1 addition & 1 deletion src/lang/ar.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use regex::Regex;

/// Arabic Language
///
/// Designed for the included Javascript implementation. See `js/lunr.ar.js`.
/// Designed to be compatibile with the included Javascript implementation. See `js/lunr.ar.js`.
pub struct Arabic {}

impl Arabic {
Expand Down

0 comments on commit d84113c

Please sign in to comment.