Deploying your contracts

When it comes to deploying, there are no plugins that implement a deployment system for Buidler yet, but there's an open issue with some ideas and we'd value your opinion on how to best design it.

In the meantime, we recommend deploying your smart contracts using scripts. You can deploy the Greeter contract from the sample project by creating a file scripts/deploy.js with these contents

// This script uses @nomiclabs/buidler-truffle5
const Greeter = artifacts.require("Greeter");

async function main() {
  const greeter = await"Hello, world!");

  console.log("Greeter address:", greeter.address);

  .then(() => process.exit(0))
  .catch(error => {

You can run it with

npx buidler run --network your-network scripts/deploy.js

Truffle migrations support

You can use Buidler alongside Truffle if you want to use its migration system. Your contracts written using Buidler will just work with Truffle.

All you need to do is installing Truffle, and follow their migrations guide.

Last Updated: 1/22/2020, 3:14:48 PM