How do you upload/edit files on your web development server?
For a long time now I have been using a local XAMPP installation on my OS X machine for all my web development. Because updating/maintaing XAMPP is such a pain, I set up an Ubuntu server for my web development.
I would like to know what you think is the best/easiest way to connect to your main development server to edit the files. What protocol do you use (smb, webdav, fdp, ldap, etc.)? Also, do you leave the files on your machine and let the serve开发者_Go百科r read the files form your hard drive (e.g. smb via a smb) or do you leave the files on the server?
I would go with SMB as your means of file transfer. How you do this is up to you. It depends on how often your files are accessed, how often they are updated, etc. If you plan on updating the files often (i.e. if you are in a rapid dev phase) then you can link them like you talked about. If the updating is infrequent and the amount of requests are high, upload them to the server. This will decrease the amount of stress on your LAN as the files are requested; in the other method the route would have been modem -- SMB server -- SMB share -- SMB server -- modem, wheras this way it is modem -- SMB server -- modem.
I use an Ubuntu Virtual Machine running the web server, git and vim. So I backup everything my Vim configuration and server config. For me is the fastest way to recover from a crash in example.
Also, you can use vim
through ssh
by
vim scp://myuser@server.com//home/myuser/file
A simpler example is to view source with an editor syntax, indent
vim http://domain.com
You can save ssh credentials too
I normally use Aptana (an Eclipse derivative) over ssh/sftp to edit the files directly on my server.
If you need to transfer files I suggest using something like FileZilla which will let you connect over ftp or ssh/sftp.
I used to map a SMB share of my LAMP server and edit the PHP files directly with Dreamweaver. Worked really well.
Lol, i'm the first one in the testimonial here. Oh memories.
精彩评论