-
Notifications
You must be signed in to change notification settings - Fork 102
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
Rework build on import #374
Conversation
@hohwille there are changes in the ide script I did not intend 3.3.0 vs variable. Is there any magic about this aspect in place I do not know? |
then | ||
cd "${project_path}/${project_build_path}" || exit 255 | ||
doDevonCommand build | ||
doDevonCommand build ${project_build_params} |
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.
But that's just passing parameters.
As of our last discussion, I even thought of running doDevonCommand ${project_post_build_command} and let the user specify what to do. So a user could even decide to do something like py doSomeGreatSetup
.
Even the question is here whether we should also support anything like also git bash standard commands, such that I could process something like an sed command or anything like this.
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.
I was thinking about security problems this might introduce, if users provide something like rm -rf /
as build command.
We have to check which level of security we want here and what doDevonCommand
provides.
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.
Ok. My view on that is simple:
With great power comes great responsibility. I don't think that we have to discuss about attackers but just about faulty configurations. But in my opinion it's quite obvious that you should not put here any cd / && rm -Rf :)
But for me it would be even ok if we simply skip execution possibilities of any non devonfw command.
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.
Then you would propose?
doDevonCommand ${project_build_cmd}
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.
yes
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.
et voilà!
|
||
doDebug "Project (Path: ${project_path}, Url: ${project_git_url}, Branch: ${project_git_branch}, Eclipse: ${project_eclipse}, Workspace: ${project_workspace}, Workingsets: ${project_workingsets})" | ||
doDebug "Pull or clone git project ${project_path}..." | ||
project_workspace_path="${DEVON_IDE_HOME}/workspaces/${project_workspace}" | ||
mkdir -p "${project_workspace_path}" | ||
cd "${project_workspace_path}" || exit 255 | ||
doGitPullOrClone "${project_path}" "${project_git_url}" "${project_git_branch}" | ||
if [ -n "${project_build_path}" ] | ||
doDebug "Building project with params: ${project_build_params}" |
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.
old reference in debug log
@maihacke |
Yes that's true. I checked a fresh install, without "pre-loading" libgs via |
I created a PR with the necessary changes to ide-settings |
Proposal to fix #372
Users have to provide params for the build command (e.g. dependency:go-offline to just download libs). Without params build is skipped.