Trying to find a simple way to do upload only modified files through FTP

前端 未结 7 1752
野趣味
野趣味 2021-01-12 18:43

Need to find a way to upload files to my server through FTP. But only the ones that have been modified. Is there a simple way of doing that? Command line ftp client or scr

7条回答
  •  遥遥无期
    2021-01-12 19:13

    git-ftp works really nice:

    apt-get install git-ftp
    

    in the application folder:

    git config git.ftp.xxxx.url ftpservice.server.com/root/dir/for/ftp
    git config git.ftp.xxxx.user myUsername
    git config git.ftp.xxxx.password myPassword
    

    following only if target is up-to-date by other ftp client (it changes ftpservice.server.com/root/dir/for/ftp/git-ftp.log to current commit)

    git ftp catchup --scope xxxx
    

    //editing sources//

    git commit -m "new version"
    git ftp push --scope xxxx
    

    and you can see what hapens:

    git ftp show --scope xxxx
    git ftp log --scope xxxx
    

提交回复
热议问题