Jenkins execution shell command prompt cannot find the command resolution

Source: Internet
Author: User

Execute the shell script with Jenkins and execute a command:

2

Tips:

[ADB] $/bin/sh-xe/users/xxxxx/tools/apache-tomcat-8.5.30/temp/jenkins8525959692743554347.sh+ adb shell input KeyEvent 26/users/xxxxx/tools/apache-tomcat-8.5.30/temp/jenkins8525959692743554347.sh:line 4:adb:command not Foundbuild Step ' execute shell ' marked build as Failurefinished:failure


Cause: Executing an environment variable in the Jenkins shell that does not load/etc/profile . bash_profile
You need to add a statement in front of the shell command:
#!/bin/bash-Il
#!/bin/bash-

This will enable the command to be executed normally.

[ADB] $/bin/bash-il/users/xxxx/tools/apache-tomcat-8.5.30/temp/jenkins3562542453282352376.shbash:no job control in This shellrestored session:2018 May 4 Friday 15:12 55 seconds cstsaving session......saving history......completed. Finished:success




Jenkins execution shell command prompt cannot find the command resolution

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.