Linux compile make file error "/bin/bash^m: Bad interpreter, use grep to quickly locate code location

Source: Internet
Author: User

One, Linux under compile make file error "/bin/bash^m: Bad Interpreter

Reference article: Http://blog.csdn.net/liuqiyao_01/article/details/41542101#comments

The results of your own tests:

"1" Creates a new file using the editing tools under Windows doc2unix.sh

#!/usr/bin/env  bash# testpid=$ (PSgrep grep grep-grep Master | awk ' {print $} ' )echo $PID

Use cat-v under Linux to view

The red part is the basis of the problem.

"2" Using Linux tools Doc2unix Convert to continue test, the effect of the conversion

2. Use grep to quickly locate the code location

Reference article: http://blog.csdn.net/diaoxuesong/article/details/44104781

Directly, search for linux-share content in the /mnt/hgfs/linux-share/lua/lua_project_v0.01/bin/ directory:

Parameter description:
N-Travel number
R-Traverse
E-Use regular expressions

Linux compile make file error "/bin/bash^m: Bad interpreter, use grep to quickly locate code location

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.