I need to be able to remotely log into web servers for my clients and edit code remotely. I mostly use this for CSS changes, but also am starting to play with PHP as well. <
Open Filezilla -> Edit -> Settings -> File Editing -> Filetype associations
Now you will have "Custom filetype associations:" situated on the right pane of the window. Over there you have to write the command for opening VSCode for PHP files.
Step 1: Search and locate the VSCode Exe file setup install directory on your computer. In my case it was (C:\Users\Shubham\AppData\Local\Programs\Microsoft VS Code/Code.exe)
Step 2: Copy the directory path link of the ".exe" file and come back to the "Custom filetype associations:" inside Filezilla.
Step 3: Now type "php" then give space & paste the directory path that you have copied inside double quotes and then again give space and write "-open". The final code should look something like this
php "C:\Users\Shubham\AppData\Local\Programs\Microsoft VS Code/Code.exe" -open
Step 4: Click the Okay Button and have a coffee.
There are several approaches to this that are all editor-agnostic.
First, there is sshfs
, which is cross-platform and you can install via your OS package manager. A simple approach would be as following:
mkdir -p ~/mnt/server
sshfs user@server.example.com:/path/on/server ~/mnt/server
Afterwards, you have the complete folder structure from server.example.com
locally available at ~/mnt/server
. Make sure you set up SSH keys to avoid entering the user password every time. You can find tutorials on that everywhere on the net.
For servers that only offer FTP access (shared hosting and the like), you can use curlftpfs
in the same fashion.
To close the connection, simply unmount:
umount ~/mnt
For a GUI-based approach, you have several options. There is Transmit (macOS), which features mounting connections as volumes, Forklift (macOS) which is a Finder replacement that can do the same, ExpanDrive (macOS/Windows) and my favorite Mountain Duck (macOS/Windows).
If you plan to move lots of data, especially a lot of small files, Mountain Duck performs the best in my experience.