Re: editing linux conf files on windows?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hello is there a windows text editor that will save and
edit conf files eg I want to log in via sftp grab a conf
file from linux box configure it on windows then save it
in the unix format that it came in put it back in the dir
on my linux box there a editor that I can edit my conf
files with?

You've got a couple options:

1) you can ssh into the remote box and edit it with a linux editor. This is usually the approach I take, and it works quite well for me.

2) you can do as you describe, and FTP the file, then use a Unix-aware editor on Windows, and then FTP the file back. In addition to the editors mentioned by Humberto, there's vim/gvim. The nice thing about learning this beast is that it runs on both Windows and Linux (and BSD, and MacOS, and...)

3) you can use a network/sftp aware editor. Vim has the "netrw" plugin which allows you to directly edit files over FTP, SFTP, HTTP, DAV, RCP, rsync and others. There's plenty of online help in Vim on the netrw plugin at

	:help netrw

I'm afraid, being a vim-user, I don't know of any other editors that allow this. I presume emacs can do the same, but I wouldn't know where to start, using it.

4) lastly, you can do exactly as you're currently doing, only exploit FTP's built-in ability to do DOS-to-UNIX line-ending conversion. If you FTP the file in ASCII mode (rather than BINARY mode), it will translate the line-endings to your local (Windows) scheme. You can then edit the file with whatever editor you like. Then, when you FTP it back, just make sure that it's in ASCII mode again, and FTP will do the translation from DOS line-endings to UNIX line-endings as it uploads the file

Hope this gives you some options to explore on how to work best.

-tim



_______________________________________________

Blinux-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/blinux-list

[Index of Archives]     [Linux Speakup]     [Fedora]     [Linux Kernel]     [Yosemite News]     [Big List of Linux Books]