Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion snippets/csharp/Snippets.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Nostr.Sdk" Version="0.43.1" />
<PackageReference Include="Nostr.Sdk" Version="0.44.0" />
</ItemGroup>

</Project>
41 changes: 14 additions & 27 deletions snippets/flutter/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,18 @@ packages:
dependency: transitive
description:
name: _fe_analyzer_shared
sha256: f256b0c0ba6c7577c15e2e4e114755640a875e885099367bf6e012b19314c834
sha256: da0d9209ca76bde579f2da330aeb9df62b6319c834fa7baae052021b0462401f
url: "https://pub.dev"
source: hosted
version: "72.0.0"
_macros:
dependency: transitive
description: dart
source: sdk
version: "0.3.2"
version: "85.0.0"
analyzer:
dependency: transitive
description:
name: analyzer
sha256: b652861553cd3990d8ed361f7979dc6d7053a9ac8843fa73820ab68ce5410139
sha256: "974859dc0ff5f37bc4313244b3218c791810d03ab3470a579580279ba971a48d"
url: "https://pub.dev"
source: hosted
version: "6.7.0"
version: "7.7.1"
args:
dependency: transitive
description:
Expand Down Expand Up @@ -58,18 +53,18 @@ packages:
dependency: transitive
description:
name: characters
sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605"
sha256: f71061c654a3380576a52b451dd5532377954cf9dbd272a78fc8479606670803
url: "https://pub.dev"
source: hosted
version: "1.3.0"
version: "1.4.0"
collection:
dependency: transitive
description:
name: collection
sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a
sha256: "2f5709ae4d3d59dd8f7cd309b4e023046b57d8a6c82130785d2b0e5868084e76"
url: "https://pub.dev"
source: hosted
version: "1.18.0"
version: "1.19.1"
convert:
dependency: transitive
description:
Expand Down Expand Up @@ -195,14 +190,6 @@ packages:
url: "https://pub.dev"
source: hosted
version: "1.3.0"
macros:
dependency: transitive
description:
name: macros
sha256: "0acaed5d6b7eab89f63350bccd82119e6c602df0f391260d0e32b5e23db79536"
url: "https://pub.dev"
source: hosted
version: "0.1.2-main.4"
matcher:
dependency: transitive
description:
Expand All @@ -223,10 +210,10 @@ packages:
dependency: transitive
description:
name: meta
sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7
sha256: e3641ec5d63ebf0d9b41bd43201a66e3fc79a65db5f61fc181f04cd27aab950c
url: "https://pub.dev"
source: hosted
version: "1.15.0"
version: "1.16.0"
mime:
dependency: transitive
description:
Expand Down Expand Up @@ -328,7 +315,7 @@ packages:
dependency: transitive
description: flutter
source: sdk
version: "0.0.99"
version: "0.0.0"
source_map_stack_trace:
dependency: transitive
description:
Expand Down Expand Up @@ -421,10 +408,10 @@ packages:
dependency: transitive
description:
name: vector_math
sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803"
sha256: d530bd74fea330e6e364cda7a85019c434070188383e1cd8d9777ee586914c5b
url: "https://pub.dev"
source: hosted
version: "2.1.4"
version: "2.2.0"
vm_service:
dependency: transitive
description:
Expand Down Expand Up @@ -482,5 +469,5 @@ packages:
source: hosted
version: "3.1.2"
sdks:
dart: ">=3.5.3 <4.0.0"
dart: ">=3.8.0-0 <4.0.0"
flutter: ">=3.3.0"
2 changes: 1 addition & 1 deletion snippets/js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"type": "module",
"license": "MIT",
"dependencies": {
"@rust-nostr/nostr-sdk": "0.43.0",
"@rust-nostr/nostr-sdk": "0.44.0",
"bip39": "^3.1.0"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion snippets/kotlin/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ repositories {

dependencies {
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.7.3")
implementation("org.rust-nostr:nostr-sdk-jvm:0.43.1")
implementation("org.rust-nostr:nostr-sdk-jvm:0.44.0")
}

tasks.test {
Expand Down
2 changes: 1 addition & 1 deletion snippets/python/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
mnemonic==0.21
nostr-sdk==0.43.1
nostr-sdk==0.44.0
pyright==1.1.399
2 changes: 1 addition & 1 deletion snippets/python/src/messages/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def client_message():
message = ClientMessage.from_json('["REQ","ABC123",{"#p":["421a4dd67be773903f805bcb7975b4d3377893e0e09d7563b8972ee41031f551"]}]')
print(f" - ENUM: {message.as_enum()}")
f = Filter().pubkey(keys.public_key())
message = ClientMessage.from_enum(cast(ClientMessageEnum, ClientMessageEnum.REQ("ABC123", filter=f)))
message = ClientMessage.from_enum(cast(ClientMessageEnum, ClientMessageEnum.REQ("ABC123", filters=[f])))
print(f" - JSON: {message.as_json()}")
# ANCHOR_END: parse-message

Expand Down
6 changes: 3 additions & 3 deletions snippets/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ version = "0.1.0"
edition = "2021"

[dependencies]
nostr-sdk = { version = "0.43", features = ["all-nips"] }
nostr-relay-builder = "0.43"
nwc = "0.43"
nostr-sdk = { version = "0.44", features = ["all-nips"] }
nostr-relay-builder = "0.44"
nwc = "0.44"
tokio = { version = "1", features = ["rt-multi-thread", "macros"] }

[[bin]]
Expand Down
2 changes: 1 addition & 1 deletion snippets/rust/src/nip17.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use nostr_relay_builder::prelude::*;

pub async fn run() -> Result<()> {
let relay = MockRelay::run().await?;
let url = relay.url();
let url = relay.url().await;

// ANCHOR: nip17
// Sender
Expand Down
2 changes: 1 addition & 1 deletion snippets/swift/Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ let package = Package(
name: "NostrSnippets",
platforms: [.macOS(.v12)],
dependencies: [
.package(url: "https://github.com/rust-nostr/nostr-sdk-swift", from: "0.43.1")
.package(url: "https://github.com/rust-nostr/nostr-sdk-swift", from: "0.44.0")
],
targets: [
.executableTarget(
Expand Down
48 changes: 31 additions & 17 deletions src/sdk/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ Add the `nostr-sdk` dependency in your `Cargo.toml` file:

```toml
[dependencies]
nostr-sdk = "0.43"
nostr-sdk = "0.44"
```

Alternatively, you can add it directly from `git` source:

```toml
[dependencies]
nostr-sdk = { git = "https://github.com/rust-nostr/nostr", tag = "v0.43.0" }
nostr-sdk = { git = "https://github.com/rust-nostr/nostr", tag = "v0.44.0" }
```

```admonish info
Expand All @@ -43,7 +43,7 @@ pip install nostr-sdk
Alternatively, you can manually add the dependency in your `requrements.txt`, `setup.py`, etc.:

```
nostr-sdk==0.43.1
nostr-sdk==0.44.0
```

Import the library in your code:
Expand Down Expand Up @@ -100,7 +100,7 @@ Alternatively, you can manually add the dependency in your `package.json` file:
```json
{
"dependencies": {
"@rust-nostr/nostr-sdk": "0.43.0"
"@rust-nostr/nostr-sdk": "0.44.0"
}
}
```
Expand Down Expand Up @@ -154,7 +154,7 @@ repositories {
}

dependencies {
implementation("org.rust-nostr:nostr-sdk:0.43.1")
implementation("org.rust-nostr:nostr-sdk:0.44.0")
}
```

Expand All @@ -166,7 +166,19 @@ repositories {
}

dependencies {
implementation("org.rust-nostr:nostr-sdk-jvm:0.43.1")
implementation("org.rust-nostr:nostr-sdk-jvm:0.44.0")
}
```

### KMP

```kotlin
repositories {
mavenCentral()
}

dependencies {
implementation("org.rust-nostr:nostr-sdk-kmp:0.44.0")
}
```

Expand All @@ -182,14 +194,15 @@ import rust.nostr.sdk.*

The following OS and architectures are supported:

| OS | x86_64 | aarch64 | armv7 | i686 | riscv64 | Package |
|---------------|--------|---------|-------|------|---------|-----------------|
| Android | ✅ | ✅ | ✅ | ✅ | ❌ | `nostr-sdk` |
| Linux (GLIBC) | ✅ | ✅ | ✅ | ✅ | ✅ | `nostr-sdk-jvm` |
| Linux (MUSL) | ✅ | ✅ | ✅ | ✅ | ✅ | `nostr-sdk-jvm` |
| FreeBSD | ✅ | ❌ | ❌ | ❌ | ❌ | `nostr-sdk-jvm` |
| macOS | ✅ | ✅ | ❌ | ❌ | ❌ | `nostr-sdk-jvm` |
| Windows | ✅ | ✅ | ❌ | ✅ | ❌ | `nostr-sdk-jvm` |
| OS | x86_64 | aarch64 | armv7 | i686 | riscv64 | Package |
|---------------|--------|---------|-------|------|---------|-------------------------------------|
| Android | ✅ | ✅ | ✅ | ✅ | ❌ | `nostr-sdk` and `nostr-sdk-kmp` |
| iOS | ✅ | ✅ | ❌ | ❌ | ❌ | `nostr-sdk-kmp` |
| Linux (GLIBC) | ✅ | ✅ | ✅ | ✅ | ✅ | `nostr-sdk-jvm` and `nostr-sdk-kmp` |
| Linux (MUSL) | ✅ | ✅ | ✅ | ✅ | ✅ | `nostr-sdk-jvm` and `nostr-sdk-kmp` |
| FreeBSD | ✅ | ❌ | ❌ | ❌ | ❌ | `nostr-sdk-jvm` and `nostr-sdk-kmp` |
| macOS | ✅ | ✅ | ❌ | ❌ | ❌ | `nostr-sdk-jvm` and `nostr-sdk-kmp` |
| Windows | ✅ | ✅ | ❌ | ✅ | ❌ | `nostr-sdk-jvm` and `nostr-sdk-kmp` |

Are you interested in other platforms? Open an issue [here](https://github.com/rust-nostr/nostr-sdk-ffi).

Expand Down Expand Up @@ -241,7 +254,7 @@ as a package dependency in Xcode.
Add the following to the dependency array in your `Package.swift`:

``` swift
.package(url: "https://github.com/rust-nostr/nostr-sdk-swift.git", from: "0.43.1"),
.package(url: "https://github.com/rust-nostr/nostr-sdk-swift.git", from: "0.44.0"),
```

### Supported platforms
Expand Down Expand Up @@ -270,7 +283,7 @@ Are you interested in other platforms? Open an issue [here](https://github.com/r
The `Nostr.Sdk` package is available on [nuget](https://www.nuget.org/packages/Nostr.Sdk):

```bash
dotnet add package Nostr.Sdk --version 0.43.1
dotnet add package Nostr.Sdk --version 0.44.0
```

### Requirements and supported platforms
Expand All @@ -281,7 +294,8 @@ The following OS and architectures are supported:

| OS | x86_64 | aarch64 | armv7 | i686 | riscv64 |
|---------------|--------|---------|-------|------|---------|
| Android | ❌ | ❌ | ❌ | ❌ | ❌ |
| Android | ✅ | ✅ | ✅ | ✅ | ❌ |
| iOS | ✅ | ✅ | ❌ | ❌ | ❌ |
| Linux (GLIBC) | ✅ | ✅ | ✅ | ✅ | ✅ |
| Linux (MUSL) | ✅ | ✅ | ✅ | ✅ | ✅ |
| FreeBSD | ✅ | ❌ | ❌ | ❌ | ❌ |
Expand Down