Skip to content

Commit eaa9fbc

Browse files
Rename to programs - and prefix internal crates with entropy-programs- (#52)
* Rename to programs * Missed name changes --------- Co-authored-by: jakehemmerle <[email protected]>
1 parent 0db40ea commit eaa9fbc

File tree

41 files changed

+146
-146
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+146
-146
lines changed

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ Thanks for contributing to the project! Please consider the following in PRs.
44

55
## Conventions
66

7-
Packages should use the `ec` prefix, which stands for "Entropy Constraints". For example, `ec-core` is the "Entropy Constraints Core" package, and `ec-acl` is the "Entropy Constraints Access Control List" package.
7+
Packages should use the `entropy-programs` prefix, which stands for "Entropy Programs". For example, `entropy-programs-core` is the "Entropy Programs Core" package, and `entropy-programs-acl` is the "Entropy Programs Access Control List" package.

Cargo.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
[workspace]
2-
members = ["constraints", "core", "acl", "evm", "runtime", "examples/*"]
2+
members = ["programs", "core", "acl", "evm", "runtime", "examples/*"]
33
resolver = "2"
44

55
[workspace.dependencies]
6-
ec-constraints = { path = "constraints", default-features = false }
7-
ec-core = { path = "core", default-features = false }
8-
ec-acl = { path = "acl", default-features = false }
9-
ec-evm = { path = "evm", default-features = false }
10-
ec-runtime = { path = "runtime", default-features = false }
6+
entropy-programs = { path = "programs", default-features = false }
7+
entropy-programs-core = { path = "core", default-features = false }
8+
entropy-programs-acl = { path = "acl", default-features = false }
9+
entropy-programs-evm = { path = "evm", default-features = false }
10+
entropy-programs-runtime = { path = "runtime", default-features = false }
1111
wit-bindgen = { version = "0.7.0", default_features = false }
1212
risc0-zkvm = { git = "https://github.com/risc0/risc0", tag = "v0.18.0", default-features = false }
1313
risc0-build = { git = "https://github.com/risc0/risc0", tag = "v0.18.0" }

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ This repository contains libraries, toolchains, utilities, and specifications fo
99
### Build Requirements
1010

1111
Besides the latest stable Rust toolchain, you will also need to install:
12+
1213
- [cargo component v0.2.0](https://github.com/bytecodealliance/cargo-component#installation), a Cargo extension for building Wasm components.
1314
- [wasm-tools](https://github.com/bytecodealliance/wasm-tools#installation), to be used by `cargo-component`.
1415

acl/Cargo.toml

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
11
[package]
2-
name = "ec-acl"
2+
name = "entropy-programs-acl"
33
version = "0.1.0"
44
authors = ["Entropy Cryptography <[email protected]>"]
55
homepage = "https://entropy.xyz/"
66
license = "AGPL-3.0-or-later"
7-
repository = "https://github.com/entropyxyz/constraints"
7+
repository = "https://github.com/entropyxyz/programs"
88
edition = "2021"
99

10-
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
11-
1210
[dependencies]
13-
ec-core = { path = "../core", default-features = false }
14-
ec-evm = { path = "../evm", default-features = false, optional = true }
11+
entropy-programs-core = { path = "../core", default-features = false }
12+
entropy-programs-evm = { path = "../evm", default-features = false, optional = true }
1513

1614
serde = { version = "1.0", default-features = false }
1715
codec = { package = "parity-scale-codec", version = "3.0.0", default-features = false, features = [
@@ -21,5 +19,5 @@ scale-info = { version = "2.1.0", default-features = false }
2119

2220
[features]
2321
default = ["std"]
24-
evm = ["dep:ec-evm"]
25-
std = ["ec-core/std", "codec/std", "evm"]
22+
evm = ["dep:entropy-programs-evm"]
23+
std = ["entropy-programs-core/std", "codec/std", "evm"]

acl/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
# `evm-acl`
1+
# `entropy-programs-acl`
22

33
Provides access control list functionality over generic architectures.

acl/src/lib.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ use core::fmt::Debug;
55

66
use codec::MaxEncodedLen;
77
use codec::{Decode, Encode};
8-
pub use ec_core::{Architecture, Error as CoreError, SatisfiableForArchitecture};
8+
pub use entropy_programs_core::{Architecture, Error as CoreError, SatisfiableForArchitecture};
99

1010
#[cfg(feature = "evm")]
11-
pub use ec_evm::{Evm, NameOrAddress, H160};
11+
pub use entropy_programs_evm::{Evm, NameOrAddress, H160};
1212

1313
use scale_info::TypeInfo;
1414
use serde::{Deserialize, Serialize};
@@ -65,7 +65,7 @@ impl<A: Default> Default for Acl<A> {
6565
}
6666

6767
// TODO This needs to be generic over any architecture (use GetRecipient and GetSender traits)
68-
// TODO Move to `ec-evm` crate?
68+
// TODO Move to `entropy-programs-evm` crate?
6969
#[allow(clippy::needless_collect)]
7070
#[cfg(feature = "evm")]
7171
impl SatisfiableForArchitecture<Evm> for Acl<<Evm as Architecture>::AddressRaw> {

acl/src/tests.rs

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#![cfg(test)]
22

3-
use ec_core::{Acl, AclKind};
3+
use entropy_programs_core::{Acl, AclKind};
44
use ethers_core::types::{NameOrAddress, TransactionRequest, H160};
55

66
use crate::Evaluate;
@@ -59,11 +59,21 @@ fn test_acl_functions_properly() {
5959
};
6060

6161
// should only block whitelisted and null recipient txs
62-
assert!(denylisted_acl.clone().is_satisfied_by(to_address_2_tx.clone()).is_ok());
63-
assert!(denylisted_acl.clone().is_satisfied_by(to_address_3_tx.clone()).is_ok());
62+
assert!(denylisted_acl
63+
.clone()
64+
.is_satisfied_by(to_address_2_tx.clone())
65+
.is_ok());
66+
assert!(denylisted_acl
67+
.clone()
68+
.is_satisfied_by(to_address_3_tx.clone())
69+
.is_ok());
6470

65-
assert!(denylisted_acl.is_satisfied_by(to_address_1_tx.clone()).is_err());
66-
assert!(allowlisted_acl.is_satisfied_by(to_null_recipient_tx.clone()).is_err());
71+
assert!(denylisted_acl
72+
.is_satisfied_by(to_address_1_tx.clone())
73+
.is_err());
74+
assert!(allowlisted_acl
75+
.is_satisfied_by(to_null_recipient_tx.clone())
76+
.is_err());
6777

6878
let allowlisted_acl_with_null_recipient = Acl::<[u8; 20]> {
6979
addresses: vec![evm_address_1],

constraints/Cargo.toml

Lines changed: 0 additions & 23 deletions
This file was deleted.

constraints/README.md

Lines changed: 0 additions & 3 deletions
This file was deleted.

core/Cargo.toml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
[package]
2-
name = "ec-core"
2+
name = "entropy-programs-core"
33
version = "0.1.0"
44
authors = ["Entropy Cryptography <[email protected]>"]
55
homepage = "https://entropy.xyz/"
66
license = "AGPL-3.0-or-later"
7-
repository = "https://github.com/entropyxyz/constraints"
7+
repository = "https://github.com/entropyxyz/programs"
88
edition = "2021"
99

10-
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
11-
1210
[dependencies]
1311
getrandom = { version = "0.2", default-features = false, features = ["custom"] }
1412
witgen = "0.15.0"
@@ -21,8 +19,8 @@ wit-bindgen = { version = "0.7.0" }
2119
# wasmtime ={ version = "10.0.1", default-features = false, features = ["component-model"] }
2220

2321
[dev-dependencies]
24-
ec-acl = { path = "../acl", default-features = false, features = ["evm"] }
25-
ec-evm = { path = "../evm", default-features = false }
22+
entropy-programs-acl = { path = "../acl", default-features = false, features = ["evm"] }
23+
entropy-programs-evm = { path = "../evm", default-features = false }
2624

2725
[features]
2826
default = ["std"]

0 commit comments

Comments
 (0)