Commit graph

28 commits

Author SHA1 Message Date
Damien Elmes
f6d5d4ea26 rspy version 2020-03-06 19:15:02 +10:00
Damien Elmes
0aa0c42d20 update to failure 0.1.7 2020-03-06 15:08:58 +10:00
Damien Elmes
0b4a7c1d10 work around bug in failure crate 2020-03-05 11:06:44 +10:00
Damien Elmes
c97b37b7ae make logging explicit, and support logging to a file 2020-02-29 20:44:01 +10:00
Alan Du
a6751c893b Update blake3 to 0.2 2020-02-26 22:50:48 -05:00
Alan Du
a6441dd4e0 Update prost-build version to 0.6
This is the same version as Prost, and lets us reduce the number of deps
we have to compile
2020-02-26 22:48:16 -05:00
Damien Elmes
1f6e7805ec add workaround for panic on 32 bit systems
https://anki.tenderapp.com/discussions/beta-testing/1817-failed-to-generate-operands-out-of-fluentnumber-could-not-convert-string-to-integer
2020-02-25 13:22:41 +10:00
Damien Elmes
0d1a30c6d8 rework Fluent handling
- all .ftl files for a language are concatenated into a single file
at build time
- all languages are included in the binary
- external ftl files placed in the ftl folder can override the
built-in definitions
- constants are automatically generated for each string key
- dropped the separate StringsGroup enum
2020-02-23 13:22:50 +10:00
Damien Elmes
ecc055d2f4 fluent-rs git no longer required 2020-02-21 21:30:11 +10:00
Damien Elmes
b851577063 fix revision pin 2020-02-21 15:29:38 +10:00
Damien Elmes
cf1824dac5 update to latest fluent-rs and add basic locale-aware decimals
- git version pinned at the moment until the concurrency fix
lands in 0.10.2
- currently float values are hard-coded at 2 decimal places;
we should switch to using NUMBER() in the future
2020-02-21 15:29:38 +10:00
Damien Elmes
0cd1ee92ee pin coarsetime for now, as .12 requires Sierra 2020-02-17 17:55:39 +10:00
Damien Elmes
43005f00a5 bump version 2020-02-17 08:40:17 +10:00
Damien Elmes
36d2536262 add i18n support to Rust code using Fluent 2020-02-17 08:40:17 +10:00
Damien Elmes
92b76a5ba7 gather field references in Rust; media check now mostly complete 2020-02-17 08:40:17 +10:00
Damien Elmes
a0680553ea use our own trash folder instead of using the system trash
the trash crate was invoking external commands on Macs and Linux
which is slow and likely to fall over if a large number of files need
to be deleted at once.
2020-02-17 08:40:17 +10:00
Damien Elmes
9c60f2c77e log media DB change registration progress, and allow aborting it 2020-02-17 08:40:17 +10:00
Damien Elmes
a769fb6172 update rslib version automatically 2020-02-17 08:40:17 +10:00
Damien Elmes
2c27c11584 comply with manylinux wheel requirements, and vendor sqlite on Windows 2020-02-17 08:40:17 +10:00
Damien Elmes
e26ab9073b send removed files to the trash
The way the trash crate implements deletion on a Mac is ugly, and
we may need to look into alternatives.
2020-02-17 08:40:16 +10:00
Damien Elmes
78bfbef863 media sync working, but unpolished 2020-02-17 08:40:16 +10:00
Damien Elmes
6bf4b9e83e port change tracking 2020-02-17 08:40:16 +10:00
Damien Elmes
9bc38647e6 initial rs implementation of media database 2020-02-17 08:40:16 +10:00
Damien Elmes
9ec6d26db7 add another implementation of media.addFile() and cleanFilename() et al
Instead of adding an incrementing number in the conflict case,
the file hash is appended.
2020-02-17 08:40:16 +10:00
Damien Elmes
548ed31ef7 add a simple TTS field filter
This simply wraps the field in extra text that the frontend will
deal with. Also added some helpers for extracting and stripping
audio and TTS tags from the rendered text.
2020-01-20 19:16:24 +10:00
Damien Elmes
d671f091ff type: and hint: support
We may need to keep handling hints in the Python code for now until
i18n is sorted out.
2020-01-11 09:35:41 +10:00
Damien Elmes
8f3df55da2 flatten->render; pass field content in
This is paving the way to move the standard filters into Rust.

Non-empty fields are now determined in Rust, using a single regex
instead of the overkill stripHTMLMedia(). The old implementation
has been moved into the Pystache code for now.
2020-01-10 14:59:29 +10:00
Damien Elmes
2a00e0a6b0 tweaking the folder names again
hopefully that's the last of it
2020-01-03 07:48:38 +10:00
Renamed from lib-rust/Cargo.toml (Browse further)