v
v copied to clipboard
Help text and possibly wrong behaviour of 'run' command
OS: macos, Mac OS X, 10.14.6, 18G6032 V full version: V 0.3.0 3ad22eb
What did you do? v help v run something.v ls ./something
What did you expect to see? I'm not sure. Going by the "Examples" section of the help, I expected to still see my compiled example application. Going by the "Ordinary development" section of the help, I expected the compiled file to be gone by then.
What did you see instead?
I saw the compiled file to still exist.
IF this is how it's supposed to be, then the explanation of the "run" command in the help is wrong, as it says:
run Compile and run a V program. Delete the executable after the run.
IF the file was indeed supposed to be deleted, the file wasn't deleted even though it should have been deleted.
If the exe does NOT already exist, v run
will create it, run it, then delete it.
If the exe DOES already exist, v run
will regenerate it, run it, then leave it alone.
Ahh… I get it now. Thanks. I would still suggest to adjust the help text somewhat, as this is not at all how I understood it in the first place. And it's quite the same with crun (which according to the Example section would behave the the same as run, except that it wouldn't recompile if nothing had changed). The part about "deleting if and only if there wasn't any file already" is not mentioned in the help text at all.
It's a recent change. Probably should be documented.