Open cheatfate opened 4 years ago
We should move this
config.nims
file inside ofbeacon_chain
directory
Unfortunately, we have Nim files in other 7 top-level directories besides "beacon_chain".
we should embed options in this
config.nims
file into Makefile
Not a good idea, because it has NimScript logic in it, and the more we mix it with the Makefile, the harder it is to maintain.
How about passing --skipParentCfg
to the Nim compiler when you want to work on a "vendor/..." project without being affected by the top-level "config.nims"? This parameter can even be added by default to "vendor/foo/foo.nimble" without affecting NBC, in most cases.
We should move this
config.nims
file inside ofbeacon_chain
directoryUnfortunately, we have Nim files in other 7 top-level directories besides "beacon_chain".
Then, we should add this config.nims
file to all this 7 top-level directories.
I've ran into this problem myself and I've considered creating a new status-workplace
repository that will have just enough automation to create the following directory structure:
status-workspace/
├── nim-beacon-chain/
│ ├── config.nims
│ ├── beacon_chain/
│ ...
├── nim-chronos/
│ ...
├── nim-stew/
.
.
.
└── Makefile
In other words, the vendor directory becomes the top-level one. This will prepare us well for a future where we switch to lockfile-enabled version of Nimble.
I vote for everything which replaces Makefiles 👍
Because we are promoting our current development environment to other teams in Status, i think we should stop using
config.nims
file in root directory, i'm talking about https://github.com/status-im/nim-beacon-chain/blob/master/config.nims .Because of its placement it got applied for every possible package inside of vendor directory, so even if you want to work on
nim-libp2p
ornim-stew
options from thisconfig.nims
will still be used.For example because of this
config.nims
file it is impossible to usevcc
compiler and test features like it was done innim-stew
CI.This happens because of https://github.com/status-im/nim-beacon-chain/blob/master/config.nims#L8
You can say that we are using only mingw compiler, but some of the packages was made not only for mingw compiler and sometimes usage of different compiler could help to investigate problem.
Proposal: We should move this
config.nims
file inside ofbeacon_chain
directory so it will be applied to beacon_chain only, or we should embed options in thisconfig.nims
file into Makefile, so it will not affect all other packages inside ofvendor
.