Thank you for your answer.Your suggestion is very good. -i If the -i option is present, the shell is interactive. -l Make bash act as if it had been invoked as a login shell (see INVOCATION below).
-i -l can make bash login/interactive shell but I would like to know Which method is the specific implementation of the slave side I debug https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/tasks/CommandInterpreter.java#L95 but cannot debug remote slave.jar(remoting project),code logic is a bit difficult to understand so, I hope you can help me to answer this question: Slave Executing the Remote Request. Which method is the specific implementation of the slave side,I didn't find implementation method on the remoting(slave.jar) project 在 2016年6月10日星期五 UTC+8下午5:36:52,ogondza写道: > > Just to add, if it will be executed in the context of login/interactive > shell is based on the way you launch the agent (environment variables > will be inherited from shell to agent and from agent to your process) > and the way you define the bash shell script (it interprets shebang at > the beginning of the script IIRC, so can choose the interpreter and > provide options for it). > > -- > oliver > -- You received this message because you are subscribed to the Google Groups "Jenkins Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/245d9fb2-679b-4ea8-8bf7-dc2a25f557c1%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
