简体   繁体   English

提交时未做任何更改(丢失文件,请参见hg状态)

[英]Nothing changed (missing files, see hg status) when comitting

I mapped to a drive an ftp, I went and did hg init 我将一个ftp映射到一个驱动器,我hg init

then added a file, did hg add then hg commit -u username -m 'message' 然后添加了一个文件,是否先进行了hg add然后进行了hg commit -u username -m 'message'

I am getting the message nothing changed (2 missing files, see hg status) 我收到的消息nothing changed (2 missing files, see hg status)

hg status return this: hg status返回此:

X:\public_html>hg status
A .htaccess
A index.html

I can't seem to find someone else remotely close to my problem and official doc didn't help me either. 我似乎找不到远程解决我问题的人,而且官方文档也没有帮助我。

I'm out of ideas, every bit of information is appreciated. 我没有主意,每一个信息都值得赞赏。

It seems incredibly unlikely this is going to work on a FTP mapped drive. 这似乎不太可能在FTP映射的驱动器上起作用。 Version control systems rely on coherent filesystem primitives (lock counts, etc.) that your mapping software likely doesn't fake correctly enough. 版本控制系统依赖于连贯的文件系统原语(锁计数等),您的映射软件可能无法正确伪造这些原语。 Mercurial has its own protocol for moving changes to/from a computer (push and pull over HTTP or SSH) and that's the right way to get stuff to and from the machine on which the FTP server is running. Mercurial拥有自己的协议,用于将更改移入计算机或从计算机移出(通过HTTP或SSH进行推拉),这是在运行FTP服务器的计算机之间进行交换的正确方法。

That said, you might have a small bit of luck with: 也就是说,您可能会遇到一点运气:

hg commit -u username -m 'message' .htaccess index.html

if the problem is commit not detecting the files as modified/added. 如果问题是提交,则未检测到文件已被修改/添加。

It looks like the server you're FTPing to/from is a linux box, so it's already running sshd. 看来您要FTP传输到/从FTP Server的服务器是一个Linux机器,因此它已经在运行sshd。 That means you can clone to it with: 这意味着您可以使用以下方法克隆到它:

hg clone c:\localclone ssh://you@there//full/path/to/repo

and can push/pull from that URL as well. 并可以从该URL进行推送/拉取。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM