Skip to content

Commit

Permalink
feat: add uniffi.toml
Browse files Browse the repository at this point in the history
  • Loading branch information
dubadub committed Sep 6, 2024
1 parent 68e5b56 commit 5d49721
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 39 deletions.
70 changes: 40 additions & 30 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,6 @@ harness = false

[workspace]
members = [".", "playground", "bindings", "fuzz"]

[profile.release]
strip = true
12 changes: 3 additions & 9 deletions bindings/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cooklang-bindings"
version = "0.0.2"
version = "0.13.3"
edition = "2021"
authors = ["dubadub <dubovskoy.a@gmail.com>"]
description = "Cooklang Uniffi bindings"
Expand All @@ -12,18 +12,12 @@ readme = "README.md"
[dependencies]
anyhow = "1.0"
cooklang = { path = ".." }
uniffi = { git = "https://github.com/mozilla/uniffi-rs", branch = "main" }

[dev-dependencies]
uniffi = { git = "https://github.com/mozilla/uniffi-rs", features = ["bindgen-tests"], branch = "main" }

[build-dependencies]
uniffi = { git = "https://github.com/mozilla/uniffi-rs", features= ["build"], branch = "main" }
uniffi = "0.28.1"
clap_derive = { version = "4.0.0-rc.1" }

[lib]
crate-type = ["cdylib", "staticlib"]


[[bin]]
# workaround: https://mozilla.github.io/uniffi-rs/tutorial/foreign_language_bindings.html#creating-the-bindgen-binary
# This can be whatever name makes sense for your project, but the rest of this tutorial assumes uniffi-bindgen.
Expand Down
9 changes: 9 additions & 0 deletions bindings/uniffi.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[bindings.kotlin]
package_name = "org.cooklang.parser"
generate_immutable_records = true
android = true

[bindings.swift]
ffi_module_name = "CooklangParserFFI"
module_name = "CooklangParser"
generate_immutable_records = true

0 comments on commit 5d49721

Please sign in to comment.