Giter Site home page Giter Site logo

Comments (3)

xurizaemon avatar xurizaemon commented on July 3, 2024

amp checks for a template (see amp config:get apache_tpl / amp config:get nginx_tpl), but when running the phar build of amp it's not clear where you'd get this template (here) or where you'd put it ($AMPHOME/Templates?)

from amp.

totten avatar totten commented on July 3, 2024

I suspect you're right -- it's looking for templates inside the PHAR. In particular TemplateEngineFactory configures the loader to locate templates from __DIR__/views/%name%. (__DIR__ is the path to the source code of TemplateEngineFactory.php).

Adding a check to search $appDir/templates (i.e. HOME/.amp or AMPHOME) would make more sense. I think that could be done by using a ChainLoader with two FilesystemLoaders

http://symfony.com/doc/current/components/templating/introduction.html
https://github.com/symfony/templating/blob/master/Loader/ChainLoader.php

I'm really not sure what's going on with that line linked. TBH, I haven't actually used the ability to reconfigure templates...

from amp.

mickadoo avatar mickadoo commented on July 3, 2024

I also ran into this, I'm not sure if it should be in the amp config menu or just automatically detect it, but it would be nice to have either.

from amp.

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.