Skip to content

Commit

Permalink
feat(crates-io): publish gbuiltins (#4306)
Browse files Browse the repository at this point in the history
  • Loading branch information
StackOverflowExcept1on authored Oct 23, 2024
1 parent ee0d92e commit 6d8f5d4
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

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

4 changes: 2 additions & 2 deletions gbuiltins/staking/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ homepage.workspace = true
repository.workspace = true

[dependencies]
gprimitives.workspace = true
derive_more.workspace = true
parity-scale-codec = { workspace = true, features = ["derive"] }
scale-info = { workspace = true, features = ["derive"] }
gprimitives = { workspace = true, features = ["codec"] }
4 changes: 1 addition & 3 deletions gbuiltins/staking/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,14 +60,13 @@ extern crate alloc;

use alloc::vec::Vec;
use gprimitives::ActorId;
use scale_info::scale::{self, Decode, Encode};
use parity_scale_codec::{Decode, Encode};

/// Type that should be used to create a message to the staking built-in actor.
///
/// A [partial] mirror of the staking pallet interface. Not all extrinsics
/// are supported, more can be added as needed for real-world use cases.
#[derive(Encode, Decode, Clone, PartialEq, Eq, Debug)]
#[codec(crate = scale)]
pub enum Request {
/// Bond up to the `value` from the sender to self as the controller.
Bond { value: u128, payee: RewardAccount },
Expand All @@ -93,7 +92,6 @@ pub enum Request {
///
/// A "mirror" of the staking pallet's `RewardDestination` enum.
#[derive(Encode, Decode, Clone, Copy, PartialEq, Eq, Debug)]
#[codec(crate = scale)]
pub enum RewardAccount {
/// Pay rewards to the sender's account and increase the amount at stake.
Staked,
Expand Down
3 changes: 3 additions & 0 deletions utils/crates-io/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ pub const SAFE_DEPENDENCIES: &[&str] = &[
"gsdk-codegen",
"gsys",
"numerated",
"gbuiltin-bls381",
];

/// Required packages with local dependencies.
Expand All @@ -58,6 +59,8 @@ pub const SAFE_DEPENDENCIES: &[&str] = &[
/// the order.
pub const STACKED_DEPENDENCIES: &[&str] = &[
"gprimitives",
"gbuiltin-eth-bridge",
"gbuiltin-staking",
"gstd-codegen",
"gcore",
"gmeta",
Expand Down

0 comments on commit 6d8f5d4

Please sign in to comment.