foundry-multibuild icon indicating copy to clipboard operation
foundry-multibuild copied to clipboard

Support Forge flag "--skip script"

Open PaulRBerg opened this issue 2 years ago • 2 comments

Requested by Matt Solomon here.

There are two ways in which this could be implemented:

  1. Add a new skip-script input.
  2. Add a new input called skip that is a string and allows users to pass whatever they want.
    • The advantage of this would be that users could skip other directories, not just test or script
    • The disadvantage is that it would be quite complicated to implement - I need to check if Forge takes a glob path or it has to be a single directory

PaulRBerg avatar Jan 10 '24 12:01 PaulRBerg

forge's --skip does accept globs, and --skip test and --skip script are just aliases for *.t.sol and *.s.sol respectively (i.e. they don't actually skip the test and script folders, just files matching those extensions).

  • Here is where you can see it's an alias
  • Here is an example skipping with globs instead

mds1 avatar Jan 10 '24 16:01 mds1

Fantastic, thanks for the color, @mds1.

PaulRBerg avatar Jan 10 '24 16:01 PaulRBerg