2

I usually work on my project with visual studio code.

Working in team, we all use github as repository, but at the end of the release (after merging the branch develop with the master), we will upload files on the ftp server for publish the updates (web application).

The problem is that we don't know which files are modified after a long time ... for example a new feature with a month of developing in the develop branch, after the merge, we cannot search for every single file and upload it manually with filezilla. We need a ftp sync extension but with command called manually when we want.

Is there any visual studio code extension (or other methods) to use it?

I tried ftp-sync extension for VSCode but it has a bug. It uploads every files even if i specified "UploadOnSave: false". Many other users has the same problem with that extension. So If i will edit files on develop branch, it overwrites my current ftp!!

In there an alternative?

My workflow is: code on a develop branch in team, at the end merge in master, then upload in ftp ... but at the moment we carry a text file with a list of every file modified (manually written) ... very bad...

StefanoV827
  • 269
  • 6
  • 18

2 Answers2

5

I Found a git plugin called "git-ftp".

It was so easy!

Just install in 2 command line, and then for each project set:

git config git-ftp.url
git config git-ftp.username
git config git-ftp.password

Then i can just use:

git ftp push 

and it will uploads only my committed files.

StefanoV827
  • 269
  • 6
  • 18
  • **windows 10 installation** : copy the file "git-ftp" from the git-ftp zip file into the git.exe folder (found by typing `get-command git` in the VSCode terminal, or `where git` in cmd.exe) – cnlevy Jan 21 '21 at 16:56
1

If you have an active SSH access to that server, you could:

  • initialize a bare Git repository
  • push your repository to it whenever you want to update
  • setup a post-receive hook in said repository which will checkout the repository where your actual files (as in here)
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250