Does the author of a work that is publicly available under a non-commercial license have the right to use it for commercial purposes?
1 answer
"License", more fully - a license agreement - these are the conditions on which the author authorizes the use of his work. License agreements restrict users, not authors.
But there is a subtlety. And it is connected with the acceptance of corrections from the community, when the format of the work allows for such a possibility. If you publish your work in open access - someone may want to modify it. If you accept these improvements, then you will cease to be the only author of the work and lose the opportunity to use the modified work under other licenses.
With regard to the same github, any accepted pull request makes it impossible for you to change the license from the project.
Large software makers solve this problem by entering into an agreement with third-party developers on the transfer (part) of copyright to the author of the original work.