allelo
Niko PLP 3 days ago
parent ffdf99aff6
commit 3289e0d95f
  1. 5
      Cargo.lock
  2. 14
      app/allelo/src-tauri/src/lib.rs
  3. 8
      app/nextgraph/README.md
  4. 3
      app/tauri-plugin-contacts-importer/Cargo.toml
  5. 10
      app/tauri-plugin-contacts-importer/ios/.gitignore
  6. 32
      app/tauri-plugin-contacts-importer/ios/Package.swift
  7. 3
      app/tauri-plugin-contacts-importer/ios/README.md
  8. 28
      app/tauri-plugin-contacts-importer/ios/Sources/ExamplePlugin.swift
  9. 8
      app/tauri-plugin-contacts-importer/ios/Tests/PluginTests/PluginTests.swift

5
Cargo.lock generated

@ -6901,9 +6901,9 @@ dependencies = [
[[package]]
name = "tauri-plugin"
version = "2.4.0"
version = "2.5.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9946a3cede302eac0c6eb6c6070ac47b1768e326092d32efbb91f21ed58d978f"
checksum = "076c78a474a7247c90cad0b6e87e593c4c620ed4efdb79cbe0214f0021f6c39d"
dependencies = [
"anyhow",
"glob",
@ -6937,6 +6937,7 @@ dependencies = [
"serde",
"serde_json",
"tauri",
"tauri-build",
"tauri-plugin",
"thiserror 2.0.16",
]

@ -1009,13 +1009,13 @@ impl AppBuilder {
// .add_plugins(["window", "event"]),
// );
// }
if cfg!(debug_assertions) {
app.handle().plugin(
tauri_plugin_log::Builder::default()
.level(log::LevelFilter::Info)
.build(),
)?;
}
// if cfg!(debug_assertions) {
// app.handle().plugin(
// tauri_plugin_log::Builder::default()
// .level(log::LevelFilter::Info)
// .build(),
// )?;
// }
Ok(())
});
builder = builder.plugin(tauri_plugin_opener::init());

@ -63,12 +63,8 @@ export RANLIB="$NDK_HOME/toolchains/llvm/prebuilt/$(ls -1 $NDK_HOME/toolchains/l
to run the dev env :
```
## on macos
cargo tauri dev --no-watch --target x86_64-apple-darwin
## on linux
cargo tauri dev --no-watch --target x86_64-unknown-linux-gnu
## on win
cargo tauri dev --no-watch --target x86_64-pc-windows-msvc
## on macos or linux or win
cargo tauri dev --no-watch
```
to build the production app installer :

@ -15,4 +15,5 @@ serde_json = "1"
thiserror = "2"
[build-dependencies]
tauri-plugin = { version = "2.4.0", features = ["build"] }
tauri-plugin = { version = "2.5.1", features = ["build"] }
tauri-build = "2.5.1"

@ -0,0 +1,10 @@
.DS_Store
/.build
/Packages
/*.xcodeproj
xcuserdata/
DerivedData/
.swiftpm/config/registries.json
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
.netrc
Package.resolved

@ -0,0 +1,32 @@
// swift-tools-version:5.3
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
let package = Package(
name: "tauri-plugin-contacts-importer",
platforms: [
.macOS(.v10_13),
.iOS(.v13),
],
products: [
// Products define the executables and libraries a package produces, and make them visible to other packages.
.library(
name: "tauri-plugin-contacts-importer",
type: .static,
targets: ["tauri-plugin-contacts-importer"]),
],
dependencies: [
.package(name: "Tauri", path: "../.tauri/tauri-api")
],
targets: [
// Targets are the basic building blocks of a package. A target can define a module or a test suite.
// Targets can depend on other targets in this package, and on products in packages this package depends on.
.target(
name: "tauri-plugin-contacts-importer",
dependencies: [
.byName(name: "Tauri")
],
path: "Sources")
]
)

@ -0,0 +1,3 @@
# Tauri Plugin contacts-importer
A description of this package.

@ -0,0 +1,28 @@
import SwiftRs
import Tauri
import UIKit
import WebKit
class PingArgs: Decodable {
let value: String?
}
class ExamplePlugin: Plugin {
@objc public func import_contacts(_ invoke: Invoke) throws {
//let args = try invoke.parseArgs(PingArgs.self)
//invoke.resolve(["value": ""])
}
@objc public func check_permissions(_ invoke: Invoke) throws {
//let args = try invoke.parseArgs(PingArgs.self)
//invoke.resolve(["value": ""])
}
@objc public func request_permissions(_ invoke: Invoke) throws {
//let args = try invoke.parseArgs(PingArgs.self)
//invoke.resolve(["value": ""])
}
}
@_cdecl("init_plugin_contacts_importer")
func initPlugin() -> Plugin {
return ExamplePlugin()
}

@ -0,0 +1,8 @@
import XCTest
@testable import ExamplePlugin
final class ExamplePluginTests: XCTestCase {
func testExample() throws {
let plugin = ExamplePlugin()
}
}
Loading…
Cancel
Save