Giter Site home page Giter Site logo

Comments (4)

jorenbroekema avatar jorenbroekema commented on May 18, 2024 2

I understand. Extremely confusing that the ! is used to include something in an include file 🤔 🤔 but that's on git-ftp, thanks for pointing it out to me.

I'll also reference git-ftp/git-ftp#325 just to point out that there is no glob support for .git-ftp-include which makes it a sub-optimal solution for certain projects, luckily I don't really need it for my project.

Lastly, having your dist folder committed to git can be very strenuous in large corporate apps with lots of file splitting, where the amount of files can go into the thousands for the production-folder of the application.

Using 2.0.0 may be the most acceptable solution for some people, just noting here that in 2.0.0 everything works fine :P

from ftp-deploy-action.

jorenbroekema avatar jorenbroekema commented on May 18, 2024

Update: removing dist from gitignore also doesn't work, perhaps because it is still considered "untracked" and not "changed"?

from ftp-deploy-action.

SamKirkland avatar SamKirkland commented on May 18, 2024

Hey Joren,

Version 3 will only upload tracked files by default (files committed to your github project). The reason for this change was so only diffs are uploaded rather than all files on every publish. This reduces publish time for large websites from hours to minutes but requires more setup initially.

To resolve this you must create a .git-ftp-include file in the root of your project with the content !dist/ so the folder is always uploaded. Or you can commit that file to git and only diffs will be published. See docs for more information

This is actually the second issue about this today (see #42) so I'm going to make the instructions much more clear :)

I'm going to close out this issue, let me know if this doesn't resolve the issue and i'll reopen.

from ftp-deploy-action.

SamKirkland avatar SamKirkland commented on May 18, 2024

Fair feedback.

The major issue with using FTP for deployments is the lack of file diffing. Over the last year the majority of the feature requests on this action have been requests for performance improvements (make uploading faster). Going with git-ftp has some major trade-offs on initial setup. However git-ftp is much more consistent by leveraging existing git tracking rather than building a diffing library based on modified times (which has plenty of edge cases that will cause partial deployments).

For the *.js support request, which files are you attempting to avoid publishing? .js.map files? If that's the case a unique webpack build for production or manually running a find . -type f ! -name "*.js" -exec rm {} \; after the build but before the publish might be a better approach vs relying on git-ftp.

from ftp-deploy-action.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.