Giter VIP home page Giter VIP logo

Comments (12)

laktek avatar laktek commented on August 17, 2024

I tried to re-create the issue by setting up a new site with 0.5.0. But it picks the output_dir setting correctly. Are you sure the project being generated with 0.5.0?

Also, can you try to run punch g after deleting the existing output directory?

from punch.

 avatar commented on August 17, 2024

I don't think the project was generated with 0.5.0, more likely 0.4.? but have tried deleting both public and output dir's and punch g recreates the output dir.

from punch.

laktek avatar laktek commented on August 17, 2024

I actually meant the version currently used to generate the output. You can find it by running punch -v inside the project's directory.

Also, could you create a new site with Punch and see whether this issue occurs in it as well?

from punch.

 avatar commented on August 17, 2024

Yes punch -v returns 0.5.0.

I'm away from my machine at the moment (replying on phone) so will try a new project in the morning but I'm guessing there will be the same issue as it's only the config.json file that affects this, right?

from punch.

laktek avatar laktek commented on August 17, 2024

I'm not sure whether a different local installation of Punch is being used to generate the site in this instance, instead of the global version. That's why I said it would be better to test by creating a new site.

from punch.

 avatar commented on August 17, 2024

New project works fine which is weird as punch -v is returning 0.5.0 wherever I run it. I have no node_modules directory in the problem project so I can't see how it is any different running punch g there vs a new project. Very odd... does it create some hidden files that I don't know about?

from punch.

laktek avatar laktek commented on August 17, 2024

No. it doesn't create any hidden files other than the .last_published file.

Are there two config files (or a config directory) by any chance?

from punch.

 avatar commented on August 17, 2024

Also removed all old versions i.e. 0.3.? and 0.4.? from ~/.npm and still got same issue.

from punch.

 avatar commented on August 17, 2024

I should probably mention that I have a couple of extra files at the root of the folder for deployment i.e. config/deploy.rb, lib/tasks/vlad.rake and Rakefile but can't see how this would affect anything.

from punch.

laktek avatar laktek commented on August 17, 2024

The problem is caused by the config directory you're having for deploy.rb. Punch will give priority to config directory and then only move on to use the config.json file.

In this case it assumes your configurations are stored in the directory. Since they are not there it resorts to default. Can you try renaming the existing config directory? It should work.

from punch.

 avatar commented on August 17, 2024

Thanks, that does in fact solve the problem however isn't it a bad idea for punch to reserve the entire config directory?

I use Vlad, the deployment rubygem and it expects a deploy.rb file to exist in the config directory.

from punch.

laktek avatar laktek commented on August 17, 2024

True. I pushed a fix which uses the config.json file if it exists, ignoring the config directory. Try installing the version 0.5.1.

Also, it's possible to give the config file path explicitly. In that case, the generate command should run this way: punch g config.json

from punch.

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.