0.7.0-rc.18 • Published 3 days ago

bitmask-core v0.7.0-rc.18

Weekly downloads
-
License
MIT
Repository
github
Last release
3 days ago

BitMask Core

Core functionality for the BitMask wallet - https://bitmask.app

BitMask is a Bitcoin-only web wallet and browser extension for accessing decentralized web applications on the Bitcoin timechain. It is designed to support UTXO-based smart contracting protocols such as RGB, in addition to Lightning payments.

Build status Crates.io npm: bitmask-core License: MIT+APACHE Telegram

Uses

Build

This should work with either wasm-pack, trunk, or x86-64.

Some environment variables may be needed in order to compile on macos-aarch64, for more, see this.

If there are issues compiling, be sure to check you're compiling with the latest Rust version.

To build this as a NodeJS module, use: wasm-pack build --release --target bundler

Test

  1. Lint against wasm32: cargo clippy --target wasm32-unknown-unknown
  2. Run tests in browser: TEST_WALLET_SEED="replace with a 12 word mnemonic for a wallet containing testnet sats" wasm-pack test --headless --chrome

Run

To run the bitmaskd node with REST server, either for testing the web wallet, or simply for increased privacy:

cargo install --features=server --path .

Then run bitmaskd.

Development

Parts of this application are built with conditional compilation statements for wasm32 support. This is a helpful command for checking linting and correctness while also developing on desktop platforms:

cargo clippy --target wasm32-unknown-unknown --no-default-features --release

Release

Upon a new release, follow these steps:

  1. Run cargo update to update to latest deps.
  2. Run cargo +nightly udeps to see if there are any unused dependencies.

Docker

For running bitmask-core tests in Regtest Mode, please follow the steps below:

Initial Setup

  1. Load the command line: source .commands or if using fish shell, bass source .commands
  2. Build bitcoin node + electrum: docker-compose build.
  3. Up and running Docker containers: docker-compose up -d bitcoin1 electrs carbonado rgb-proxy.
  4. Download and install BDK cli: cargo install bdk-cli (We will use BDK to generate the mnemonic).
  5. Generate a new mnemonic: bdk-cli key generate.
  6. Create an environment variable called TEST_WALLET_SEED with mnemonic generated in the step 5 (only wasm32).
  7. Run the test to get regtest address for bitcoin and rgb: cargo test --test wallet -- create_wallet --exact --nocapture.
  8. Load your wallet in the bitcoin node: bc1 loadwallet default, or if using a new wallet, bc1 createwallet default.
  9. Generate new first 500 blocks: bc1 -generate 500.
  10. Send some coins to the main wallet address: bc1 sendtoaddress {MAIN_VAULT_ADDRESS} 10. Change {MAIN_VAULT_ADDRESS} with the address generated in the step 7.
  11. Mine a new block: bc1 -generate 1

Running the tests

Running the tests: cargo test -- --test-threads 1

Troubleshooting

1. After restarting the container

A.The bitcoin node does not work?

Check if your wallet is loaded. For that, run the command bitcoin1 loadwallet default.

B.The electrs node does not work?

To stop the electrs freeze, run bitcoin1 -generate.

0.7.0-rc.18

3 days ago

0.7.0-rc.17

7 days ago

0.7.0-rc.16

11 days ago

0.7.0-rc.15

11 days ago

0.7.0-rc.14

20 days ago

0.7.0-rc.13

24 days ago

0.7.0-rc.12

29 days ago

0.7.0-rc.11

1 month ago

0.7.0-rc.10

1 month ago

0.7.0-rc.9

1 month ago

0.7.0-rc.8

2 months ago

0.7.0-rc.7

3 months ago

0.7.0-rc.6

3 months ago

0.7.0-rc.5

3 months ago

0.7.0-rc.4

3 months ago

0.7.0-rc.3

3 months ago

0.7.0-beta.15

3 months ago

0.7.0-beta.12

3 months ago

0.7.0-beta.14

3 months ago

0.7.0-beta.13

3 months ago

0.7.0-rc.2

3 months ago

0.7.0-rc.1

3 months ago

0.7.0-beta.11

3 months ago

0.7.0-beta.10

5 months ago

0.6.3-rc.12

9 months ago

0.6.3-rc.13

9 months ago

0.6.3-rc.10

9 months ago

0.6.3-rc.11

9 months ago

0.6.3-rc.16

9 months ago

0.6.3-rc.17

9 months ago

0.6.3-rc.14

9 months ago

0.6.3-rc.15

9 months ago

0.6.3-rc.18

8 months ago

0.6.3-rc.19

8 months ago

0.6.3-rc.7

9 months ago

0.7.0-beta.1

7 months ago

0.6.3-rc.8

9 months ago

0.6.0-rc.3

11 months ago

0.7.0-beta.2

6 months ago

0.6.3-rc.5

9 months ago

0.6.0-rc.4

11 months ago

0.7.0-beta.3

6 months ago

0.6.3-rc.6

9 months ago

0.6.0-rc.5

10 months ago

0.6.0-rc.6

10 months ago

0.6.0-rc.7

10 months ago

0.6.3-rc.9

9 months ago

0.6.0-rc.8

10 months ago

0.6.0-rc.9

10 months ago

0.7.0-beta.8

6 months ago

0.7.0-beta.9

6 months ago

0.7.0-beta.4

6 months ago

0.6.3-rc.3

9 months ago

0.7.0-beta.5

6 months ago

0.6.3-rc.4

9 months ago

0.6.3-rc.1

9 months ago

0.7.0-beta.7

6 months ago

0.6.3-rc.2

9 months ago

0.6.0-rc.17

10 months ago

0.6.0-rc.14

10 months ago

0.6.0-rc.13

10 months ago

0.6.0-rc.16

10 months ago

0.6.0-rc.15

10 months ago

0.6.0-rc.10

10 months ago

0.6.0-rc.12

10 months ago

0.6.0-rc.11

10 months ago

0.6.4-rc.3

7 months ago

0.6.4-rc.2

7 months ago

0.6.4-rc.1

7 months ago

0.6.3-rc.20

8 months ago

0.6.3-rc.21

8 months ago

0.6.3-rc.22

7 months ago

0.6.2

9 months ago

0.6.1

10 months ago

0.6.0-beta.17

11 months ago

0.6.0-beta.16

11 months ago

0.6.0-beta.18

11 months ago

0.6.0-rc.2

11 months ago

0.6.0-beta.13

11 months ago

0.6.0-beta.12

11 months ago

0.6.0-beta.15

11 months ago

0.6.0-beta.14

11 months ago

0.6.0-beta.11

12 months ago

0.6.0-beta.10

12 months ago

0.6.0-rc.1

11 months ago

0.6.0-beta.8

12 months ago

0.6.0-beta.7

12 months ago

0.6.0-beta.9

12 months ago

0.6.0-beta.6

12 months ago

0.6.0-beta.4

12 months ago

0.6.0-beta.3

12 months ago

0.6.0-beta.5

12 months ago

0.6.0-beta.0

1 year ago

0.6.0-beta.2

1 year ago

0.6.0-beta.1

1 year ago

0.5.0

1 year ago

0.5.2

1 year ago

0.5.1

1 year ago

0.5.0-rc.2

1 year ago

0.5.0-rc.1

1 year ago

0.5.0-rc.4

1 year ago

0.5.0-rc.3

1 year ago

0.5.0-rc.6

1 year ago

0.5.0-rc.5

1 year ago

0.4.4

1 year ago

0.4.3

1 year ago

0.4.2

1 year ago

0.4.0-alpha.4

2 years ago

0.4.0-alpha.3

2 years ago

0.4.0-alpha.2

2 years ago

0.4.0-alpha.1

2 years ago

0.4.1

1 year ago

0.4.0

2 years ago

0.4.0-alpha.5

2 years ago

0.3.0

2 years ago

0.2.2

2 years ago

0.2.1

2 years ago

0.2.0

2 years ago

0.1.2

2 years ago

0.1.1

2 years ago