Compare commits

...

4 Commits

Author SHA1 Message Date
d567848cba chore: release master (#92) 2023-05-03 16:58:12 +04:00
9b942eacca feat(keypair): Make KeyFormat more convenient (#91)
* feat(keypair): Make `KeyFormat` more convenient

1. Make `KeyFormat` implement `Debug`, `Clone` and `Eq`.
2. Add `KeyPair::key_format(&self) -> KeyFormat` method.
2023-05-03 02:48:42 +07:00
c85fb16de3 chore: Fix build script (#90)
Fix build script
2023-04-18 16:42:51 +03:00
97ce5bbac7 chore(release-please): Fix publishing (#89)
Fix typo
2023-04-18 11:24:24 +03:00
11 changed files with 45 additions and 18 deletions

View File

@ -1,6 +1,6 @@
{
"trust-graph": "0.4.1",
"trust-graph": "0.4.2",
"aqua": "0.4.1",
"service": "0.4.1",
"keypair": "0.10.0"
"service": "0.4.2",
"keypair": "0.10.1"
}

View File

@ -14,9 +14,9 @@ jobs:
outputs:
releases-created: ${{ steps.release.outputs['releases_created'] }}
trust-graph-api-release-created: ${{ steps.release.outputs['aqua--release-created'] }}
trust-graph-release-created: ${{ steps.release.outputs['release-created'] }}
trust-graph-tag-name: ${{ steps.release.outputs['tag_name'] }}
trust-graph-api-release-created: ${{ steps.release.outputs['aqua--release_created'] }}
trust-graph-release-created: ${{ steps.release.outputs['trust-graph--release_created'] }}
trust-graph-tag-name: ${{ steps.release.outputs['trust-graph--tag_name'] }}
steps:
- name: Run release-please

6
Cargo.lock generated
View File

@ -963,7 +963,7 @@ dependencies = [
[[package]]
name = "fluence-keypair"
version = "0.10.0"
version = "0.10.1"
dependencies = [
"asn1_der 0.6.3",
"bs58",
@ -2897,7 +2897,7 @@ dependencies = [
[[package]]
name = "trust-graph"
version = "0.4.1"
version = "0.4.2"
dependencies = [
"bs58",
"derivative",
@ -2914,7 +2914,7 @@ dependencies = [
[[package]]
name = "trust-graph-wasm"
version = "0.4.1"
version = "0.4.2"
dependencies = [
"anyhow",
"bincode",

View File

@ -14,9 +14,7 @@ SCRIPT_DIR="$(pwd)"
(
echo "*** create builtin distribution package ***"
cd ..
mv builtin-package trust-graph
tar --exclude="package.sh" -f trust-graph.tar.gz -zcv ./trust-graph
mv trust-graph builtin-package
tar --exclude="package.sh" -f trust-graph.tar.gz -zcv --transform 's|builtin-package|trust-graph|' builtin-package
)
echo "*** done ***"

View File

@ -4,6 +4,13 @@ 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).
## [0.10.1](https://github.com/fluencelabs/trust-graph/compare/keypair-v0.10.0...keypair-v0.10.1) (2023-05-02)
### Features
* **keypair:** Make `KeyFormat` more convenient ([#91](https://github.com/fluencelabs/trust-graph/issues/91)) ([9b942ea](https://github.com/fluencelabs/trust-graph/commit/9b942eacca49d0468b4d7512667102363a6c9aa3))
## [0.10.0](https://github.com/fluencelabs/trust-graph/compare/keypair-v0.9.0...keypair-v0.10.0) (2023-03-15)

View File

@ -1,6 +1,6 @@
[package]
name = "fluence-keypair"
version = "0.10.0"
version = "0.10.1"
authors = ["Fluence Labs"]
edition = "2021"
description = "identity"

View File

@ -48,6 +48,7 @@ use std::str::FromStr;
/// ```
///
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum KeyFormat {
Ed25519,
#[cfg(not(target_arch = "wasm32"))]
@ -168,6 +169,18 @@ impl KeyPair {
}
}
/// Get the key format of this keypair.
pub fn key_format(&self) -> KeyFormat {
use KeyPair::*;
match self {
Ed25519(_) => KeyFormat::Ed25519,
#[cfg(not(target_arch = "wasm32"))]
Rsa(_) => KeyFormat::Rsa,
Secp256k1(_) => KeyFormat::Secp256k1,
}
}
/// Get the public key of this keypair.
pub fn public(&self) -> PublicKey {
use KeyPair::*;

View File

@ -4,6 +4,11 @@ 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).
* The following workspace dependencies were updated
* dependencies
* trust-graph bumped from 0.4.1 to 0.4.2
* fluence-keypair bumped from 0.10.0 to 0.10.1
## [0.4.1](https://github.com/fluencelabs/trust-graph/compare/trust-graph-wasm-v0.4.0...trust-graph-wasm-v0.4.1) (2023-04-13)

View File

@ -1,6 +1,6 @@
[package]
name = "trust-graph-wasm"
version = "0.4.1"
version = "0.4.2"
authors = ["Fluence Labs"]
edition = "2021"
description = "trust graph wasm"
@ -12,8 +12,8 @@ name = "trust-graph"
path = "src/main.rs"
[dependencies]
trust-graph = { version = "0.4.1", path = "../trust-graph" }
fluence-keypair = { version = "0.10.0", path = "../keypair" }
trust-graph = { version = "0.4.2", path = "../trust-graph" }
fluence-keypair = { version = "0.10.1", path = "../keypair" }
marine-rs-sdk = { version = "0.7.1", features = ["logger"] }
marine-sqlite-connector = "0.8.0"

View File

@ -1,5 +1,9 @@
# Changelog
* The following workspace dependencies were updated
* dependencies
* fluence-keypair bumped from 0.10.0 to 0.10.1
## [0.4.1](https://github.com/fluencelabs/trust-graph/compare/trust-graph-v0.4.0...trust-graph-v0.4.1) (2023-04-13)

View File

@ -1,6 +1,6 @@
[package]
name = "trust-graph"
version = "0.4.1"
version = "0.4.2"
authors = ["Fluence Labs"]
edition = "2021"
description = "trust graph"
@ -10,7 +10,7 @@ repository = "https://github.com/fluencelabs/trust-graph"
[dependencies]
serde = { version = "1.0.118", features = ["derive"] }
fluence-keypair = { path = "../keypair", version = "0.10.0" }
fluence-keypair = { path = "../keypair", version = "0.10.1" }
bs58 = "0.4.0"
failure = "0.1.6"
log = "0.4.11"