<p>In our context of smart contracts, <code>cabal build</code> builds the executables needed for doing <code>cabal run</code>, which we use to build the Plutus validator.</p>
<p><code>cabal repl</code>, in the other hand loads all the modules that are in your project into GHCi, which is ready to be used in interpreted code. In this context you can test your validator or your off-chain code in an interactive way, which is useful to test behavior of specific functions in your code.</p>

CC BY-SA 4.0
2022-01-17T12:14:11.933Z
2022-01-17T12:14:11.933Z
Barros
<p>What does &quot;cabal repl&quot; does and how it differentiates from &quot;cabal build&quot;?</p>
<p>the documentation says:</p>
<blockquote>
<p>loads all of the modules of the target into GHCi as interpreted bytecode</p>
</blockquote>
<p>But I dont fully understand when do I need to use that command</p>

<plutus-pioneer-program><cabal>
What is the difference between "cabal build" and "cabal repl"?
# What is the difference between "cabal build" and "cabal repl"?

(Asked by: username_0 on 2022-01-17)

What does "cabal repl" does and how it differentiates from "cabal build"?

the documentation says:

> loads all of the modules of the target into GHCi as interpreted bytecode

But I dont fully understand when do I need to use that command

**Tags:** plutus-pioneer-program, cabal

---

## 1 answers

### Answer by username_1 on 2022-01-17. Score: 3 | Accepted answer

In our context of smart contracts, `cabal build` builds the executables needed for doing `cabal run`, which we use to build the Plutus validator.

`cabal repl`, in the other hand loads all the modules that are in your project into GHCi, which is ready to be used in interpreted code. In this context you can test your validator or your off-chain code in an interactive way, which is useful to test behavior of specific functions in your code.


---

