-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix --clean
flag in federated generator
#1475
Conversation
org.lflang/src/org/lflang/federated/generator/FedFileConfig.java
Outdated
Show resolved
Hide resolved
As the whole directory is generated it makes sense to remove all of them.
--clean
flag in federated generator--clean
flag in federated generator
org.lflang/src/org/lflang/federated/generator/FedGenerator.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor change requested. Otherwise looks good!
The requested change has been made, and I am in such a hurry to get |
I think it's a good decision. Thanks for being so proactive, @petervdonovan! |
This hopefully completes the task mentioned in #1221.
This PR did......
FedGenerator::cleanIfNeeded()
just like other generators; 86681d6#diff-e0f660764015b35c4b0bf3bb21720b1f7be727746c3790043b30139de8f90671R174FedFileConfig::doClean()
, 86681d6#diff-aef6a300a7e1bac3cddb7efb7226ba4b7e59333e269617fd75d591baaad0a5e3R85So in total, it will clean
./src-gen
(which will not exist if federated),./bin
(appears to exist regardless of federated) and./fed-gen/{name}
(unlike in non-federated context, removing the whole directory makes sense as the whole directory is generated).@lhstrh mentioned to me that one more thing to do is to tell each federate to do
--clean
; I'm unsure if that is been done or not now as during federate generationcontext
which possibly containsclean
flag will be passed in:lingua-franca/org.lflang/src/org/lflang/federated/generator/FedGenerator.java
Line 160 in 86681d6
Marking this WIP until I confirm with people the expected behaviour of
--clean
under federated: would cleaning these 3 places be enough