SitePoint Sponsor

User Tag List

Results 1 to 12 of 12
  1. #1
    SitePoint Zealot lightworks's Avatar
    Join Date
    Jun 2010
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Best way to sync files and dev environment across computers?

    I'm not much of a networking guy and have been using a single desktop for quite a while. I recently got a laptop and wireless router and I'm wondering what the best options would be for syncing files, especially my xampp dev server, between the two machines. I'd like to be able to work from both at times but keep the files synced.

    Would I want to keep xampp and all my files on the desktop and connect to it from the laptop somehow? Or would I want to be running separate copies of xampp and just sync the htdocs (web root) and database folder? Should I say eff it and just work on my web server in a private directory? Or give up trying to keep both synced?

    What do you do? And, how?

    Code:
    cable modem --> router --> Win7 desktop via LAN (w/ xampp installed already)
                           --> Win7 laptop via wifi
    Thanks.

  2. #2
    SitePoint Addict
    Join Date
    Apr 2009
    Posts
    356
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    It sounds to me that a version control system like svn would work for you.
    Doug G
    =====
    "If you ain't the lead dog, the view is always the same - Anon

  3. #3
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,576
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    ^^^This man speaks the truth.

  4. #4
    SitePoint Zealot lightworks's Avatar
    Join Date
    Jun 2010
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I definitely need to get in the habit of using svn or git whether it's the solution to my current problem or not. But, since I've never used any kind of version control, I have a couple of concerns:

    1. I definitely see the value of using it for code on individual projects. But, keep in mind that I'd also like to have images (changed often during designing) and database files in my mysql folder synced. Would version control still be my solution?

    2. The other issue is that it seems like maybe it's inefficient using the cloud when, most of the time, I'll be on my home network. Or could I set some local repository in a shared folder?

    3. Lastly, do you have to check each individual file in when changes are made? Or can you check in a whole folder at a time and have only the files that have been modified updated in the repository?

    Thanks

  5. #5
    SitePoint Addict
    Join Date
    Apr 2009
    Posts
    356
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    I set up a local svn repository on a Fedora linux computer on my lan, it was pretty since svn is in the yum repositories.

    Eclipse has a subversion plugin that makes it easy to deal with php projects from any workstation I use. You check out your project then work on local copies, then commit changes back to the svn repo, and with eclipse anyway you can commit all your changes in one step.

    From a location outsite my LAN I connect using SSH when I need to visit my repo.

    NOTE: I work by myself, not in a group. I'm sure there are many many things about using svn I don't know
    Doug G
    =====
    "If you ain't the lead dog, the view is always the same - Anon

  6. #6
    SitePoint Wizard
    Join Date
    Jan 2001
    Location
    Grand Rapids, MI
    Posts
    1,284
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Setting up SVN is not the right solution and probably won't work very well. You will have to commit changes any time you want to switch machines and this isn't the idea behind a commit. A commit should be a new feature or a bug fix, not just because you are switching machines.

    The solution is to use Dropbox. You can use the LAN sync feature to keep things in sync which will make it quicker if you have large files. You can use this guide to setup symbolic links so you can keep your files other places on your disk if you wish.

    I've long had this same problem, as I use a laptop and desktop regularly and I've found that Dropbox is the best solution.

  7. #7
    Community Advisor silver trophy

    Join Date
    Nov 2006
    Location
    UK
    Posts
    2,514
    Mentioned
    37 Post(s)
    Tagged
    1 Thread(s)
    I use dropbox as well, incredibly easy to set up and use. If you're not familiar with it, worth reading through http://wiki.dropbox.com/TipsAndTricks to get an idea of other uses it can be put to other than syncing and backing up work directories.

  8. #8
    SitePoint Zealot lightworks's Avatar
    Join Date
    Jun 2010
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks. Dropbox was my first thought, but I've yet to use it either and didn't know it had a "LAN sync". I thought I would be wasting a lot of upload bandwidth constantly uploading to the cloud.

    One question, those files will still count towards my allowed storage though right? From what I'm reading it sounds like it also uploads a copy to the cloud. I'm just wondering if I can stay under 2GB for the free plan. They are really working the freemium model here (quite a jump from 2GB to 50GB).

  9. #9
    SitePoint Author silver trophybronze trophy
    wwb_99's Avatar
    Join Date
    May 2003
    Location
    Washington, DC
    Posts
    10,576
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    1. I definitely see the value of using it for code on individual projects. But, keep in mind that I'd also like to have images (changed often during designing) and database files in my mysql folder synced. Would version control still be my solution?
    Images shouldn't hurt anything modern--we store GBs of images and video in SVN here. For MySql, you should really version the database schema change scripts, databases themselves are just build artifacts.

    2. The other issue is that it seems like maybe it's inefficient using the cloud when, most of the time, I'll be on my home network. Or could I set some local repository in a shared folder?
    If you are just submitting changes, it shouldn't hurt that much. Unless you have really bad home internet connectivity.

    3. Lastly, do you have to check each individual file in when changes are made? Or can you check in a whole folder at a time and have only the files that have been modified updated in the repository?
    Typically, you check in the whole project which updates the repository with changes.

  10. #10
    SitePoint Wizard
    Join Date
    Jan 2001
    Location
    Grand Rapids, MI
    Posts
    1,284
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by lightworks View Post
    Thanks. Dropbox was my first thought, but I've yet to use it either and didn't know it had a "LAN sync". I thought I would be wasting a lot of upload bandwidth constantly uploading to the cloud.

    One question, those files will still count towards my allowed storage though right? From what I'm reading it sounds like it also uploads a copy to the cloud. I'm just wondering if I can stay under 2GB for the free plan. They are really working the freemium model here (quite a jump from 2GB to 50GB).
    Yes everything in your Dropbox counts towards the storage. It will use the LAN sync to keep local computers in sync, but it still uploads to Dropbox as well.

    2GB should be plenty, you don't have to keep files in their forever. Just keep your current projects in there and then you can archive them later. You could also use Microsoft's Live Mesh which works in a similar way assuming you only use Windows.

  11. #11
    SitePoint Addict beebs93's Avatar
    Join Date
    Jul 2010
    Location
    Vancouver, Canada
    Posts
    207
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by EastCoast View Post
    I use dropbox as well, incredibly easy to set up and use. If you're not familiar with it, worth reading through http://wiki.dropbox.com/TipsAndTricks to get an idea of other uses it can be put to other than syncing and backing up work directories.
    Yeah, DropBox is a nice simple solution.

    If you have MAMP, WAMP and LAMP running on computers in your network you can point all of them to your DropBox folder with the project files and be golden.

    Plus, you can get 250MB each time you sign up a friend (to a max of 8GB)!
    "To be truly dedicated to something
    you must be willing to betray it.
    " -SW

  12. #12
    SitePoint Zealot lightworks's Avatar
    Join Date
    Jun 2010
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for all the tips. I think I'll give both a try and see which works better for me.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •