MagicSync makes Connect more valuable by giving you a view into what files have changed between environments. MagicSync makes it easier to push or pull only the files that have had changes to them, speeding up the process.
Table of Contents:
The core benefit of using MagicSync is that only files that have changed will be displayed when deploying updates or pulling down changes. The MagicSync Viewer provides a clear view of what files are different, along with easy controls for ignoring certain files during the Connect process.
In addition to MagicSync allowing you to control exactly what is deployed, using Connect does more for your deployment process:
- Cache busting: We’ll clear your site’s cache when you launch changes.
- Backups: We back up your site every two hours when you’re pushing changes.
- Security: Unlike FTP (which exposes a direct connection to your site), MagicSync is routed through a separate micro-service before deploying.
When using MagicSync to push or pull a site, there are three main steps that Local will do before showing the Viewer.
- Local asks the server for a list of all the files located within the remote site.
- Local also creates a file list of all the files on the local site.
- Taking these two file lists, Local compares the two based on the file’s modification time.
Local only compares modification times of files within the file list and not the actual contents of those files. If you find yourself needing to manage and merge changes more granularly than at the file level, you might consider using a dedicated version control tool like Git.
All modified files option
The “all modified files” option can be thought of as a “force overwrite” of the target site by the source site. This is regardless of the modification times that Local finds when comparing the file list of the server and the local site.
So for example, if I’m pushing a local site up to Flywheel’s servers, Local will compare the two file lists, one for the local site and one for the server. It will then generate instructions to:
- Add any files that are missing on the server
- Delete all files that do not exist on the local site
- Overwrite any remote files, regardless of what the modification time is.
Notice in this screenshot, the
readme.txt file is older on the Local site, but because the “All modified files” option is selected, it is still going to overwrite the remote site.
If we compare the above image with the “only newer files” option, we see that the file that is older on the Local site, does not show up as available to be pushed: