Skip to content

metaplex-foundation/mpl-utils

Repository files navigation

Metaplex Core Utilities

Core Rust utilities for Metaplex smart contracts.

Program Tests Integration Tests SDK Tests

Metaplex Core Utilities

Name Rust Crate npm Package
Testing Utils Crate N/A
Utils Crate N/A

Development

Setting up Rust Tests

Run the build.sh script with "testing-utils" to build the shared object and put it in a directory called test-programs in the root of the project.

./build.sh testing-utils

Similarly, use test.sh to run tests:

./test.sh testing-utils

Versioning and Publishing Packages

We use the following (pre|post)(version|publish) npm scripts to manage related checks, tagging, committing and pushing the version bump.

  • preversion: ensures that the package builds and its tests pass
  • postversion: adds and commits the version bump and adds a tag indicating package name and new version, i.e. @metaplex-foundation/[email protected]
  • prepublishOnly: ensures that the package builds and its tests pass again (just to be really sure)
  • postpublish: pushes the committed change and new tag to GitHub

In order to version and then publish a package just run the following commands from the folder of the package you want to update:

  • npm version <patch|minor|major>
  • npm publish

As you note if version + publish succeeds the scripts end up pushing those updates to the master branch. Therefore, please ensure to be on and up to date master branch before running them. Please don't ever publish from another branch but only from the main one with only PR approved changes merged.

Rust Crates

Package Link Version
Testing Utils mpl-testing-utils Crate
Utils mpl-utils Crate

Reporting security issues

To report a security issue, please follow the guidance on the SECURITY page.

License

The Rust/Cargo programs are licensed under the "Apache-style" Metaplex(TM) NFT Open Source License and the JS/TS client libraries are licensed under either the MIT or the Apache licenses.

About

No description, website, or topics provided.

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published