You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was talking with @AxelKrypton about adding a codebase formatter to the sampler repo. He proposed (since the sampler repo needs SMASH anyways to be installed) that a good solution would be to write a small formatter script which reuses SMASH’s codebase-format-helper.bash internally.
For tracking purposes a small transcript from our conversation and which steps he suggested:
Change SMASH script to call the Main function only when the script is executed and not sourced. If needed, move the out-of-function lines to a function and call it accordingly.
Create a new script in the sampler that is going to be the new tool.
In it test the SMASH_DIR environment variable to check it points to a valid existing location.
Use it to source the SMASH script. This will do nothing as only functions are sourced.
Redefine the look_for_files_to_format function (I think this the only needed change) tailoring it to the sampler codebase
Assemble a new Main function if needed or just call it.
The text was updated successfully, but these errors were encountered:
I was talking with @AxelKrypton about adding a codebase formatter to the sampler repo. He proposed (since the sampler repo needs SMASH anyways to be installed) that a good solution would be to write a small formatter script which reuses SMASH’s
codebase-format-helper.bash
internally.For tracking purposes a small transcript from our conversation and which steps he suggested:
Main
function only when the script is executed and not sourced. If needed, move the out-of-function lines to a function and call it accordingly.SMASH_DIR
environment variable to check it points to a valid existing location.look_for_files_to_format
function (I think this the only needed change) tailoring it to the sampler codebaseMain
function if needed or just call it.The text was updated successfully, but these errors were encountered: