Discuz! BBS

 找回密码
 立即注册
搜索
热搜: 活动 交友 discuz
查看: 5|回复: 0

VIM Syntax error: end of file unexpected (expecting “then“) 或者Syntax...

[复制链接]

499

主题

682

帖子

4006

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
4006
发表于 前天 04:15 | 显示全部楼层 |阅读模式
Syntax error: end of file unexpected (expecting “then“) 或者Syntax error: end of file unexp

这个是unix 和 dos  的不同换行符导致的。 在vim 中写入命令:
:set fileformat=unix
:wq
即可。

ref:https://blog.csdn.net/mantouyouyou/article/details/134201798

喵喵地,整了半天。千万别用nano!
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|DiscuzX

GMT+8, 2026-4-15 05:51 , Processed in 0.011190 second(s), 19 queries .

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表