Let's say that I have an exe
that has a function called compareTwoThings
. I'd like compareTwoThings
to be able to take, as arguments, two directories that have identical file names in each: a .json
and a .fs
. In compareTwoThings
, I want to be able to read in each .json
(easy-peasy) and each .fs
file. The contents of each .fs
file will be known.
How can I read in each .fs
file and use the values in those .fs
files without them being a part of the overall project structure? Can I? I understand that to build a project and have the project "see" into the .fs
files, they need to be added to the .fsproj
file, but can I not use open
on an external file that has a module name?
Example dir structure of the proj:
myProj
|-proj
|-compareTwoThings.fs
|-myProj.fs
|-myProj.fsproj
Thing1
|-Thing1.fs
|-Thing1.json
Thing2
|-Thing2.fs
|-Thing2.json
And ultimately, the CLI statement would be something like
myProj compareTwoThings [dir to Thing1] [dir to Thing2] [output dir]
I feel like I'm overlooking something very simple here.
Edit: I do not believe that this question is related as I'm asking how to open a non-project .fs
file.