如何阻止 Filezilla 更改我的换行符? [英] How can I stop Filezilla changing my linebreaks?

查看:24
本文介绍了如何阻止 Filezilla 更改我的换行符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在从 Linux 网络服务器下载一个 perl CGI 文件.

I'm downloading a perl CGI file from a Linux web server.

它有 Unix 换行符.我在 Windows PC 上用一个不错的文本编辑器 (Geany) 编辑它,它保留了这些换行符.

It has Unix linebreaks. I edit it on a Windows PC with a decent text-editor (Geany) which preserves those linebreaks.

然后我用 Filezilla 再次上传它,它有 DOS 换行符,导致它停止工作.

I then upload it again with Filezilla and it has DOS linebreaks, which stop it working.

我知道它是 Filezilla,而不是 Geany,因为即使我只是下载它并重新上传它,问题仍然存在.

I know it's Filezilla, not Geany because even if I just download it, and re-upload it, the problem recurs.

Filezilla 每次都会询问我是否可以上传本地文件 (3611) 字节并覆盖远程文件 (3753 字节),这些数字之间的差异是我的文件中的行数.但是当我这样做时,服务器上的那个又是 3753 字节并且不起作用.

Filezilla asks me, every time, if I'm OK to upload the local file (3611) bytes and overwrite the remote file (3753 bytes), and the difference between those numbers is the number of lines in my file. But when I do that, the one on the server is 3753 bytes all over again and doesn't work.

我正在通过代理服务器,这可能是一个因素吗?真正奇怪的是,前几天我在另一台 XP PC 上做了同样的事情,结果很好.命令行 FTP 也可以正常工作.

I'm going through a proxy server, might that be a factor? The really weird thing is I did the same thing on a different XP PC just the other day and it was fine. And command-line FTP works fine too.

推荐答案

在 FileZilla 2.2.32 中,进入 Edit >设置 >文件传输设置 >ASCII/二进制.将其设置为始终二进制:应该可以解决问题.

In FileZilla 2.2.32, go Edit > Settings > File transfer settings > ASCII/Binary. Set it to always binary: that should do the trick.

在 FileZilla 3.5.0 中,设置位于编辑">设置">传输">文件类型">默认传输类型">二进制"中.

In FileZilla 3.5.0 the setting is in Edit > Settings > Transfers > File Types > Default transfer type > Binary.

这篇关于如何阻止 Filezilla 更改我的换行符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆