Skip to content

Improve PHP build setup using composer #624

Closed

Description

@jekkos

Quite interesting article on how to manage php frameworks/dependencies using composer

https://github.com/kenjis/codeigniter-composer-installer

This would allow us to update to latest CI with just one command (as with bower for frontend dependencies). It will also become easier to manage third party libraries, upstream CI translations and keep domPDF dependency up to date (which is hardwired inside our Ci install for now)

Activity

  1. daN4cat commented on Jun 7, 2016

    @daN4cat
    Collaborator

    Looks good, there are also three 3rd parties that we would need: Ion Auth, RESTful and HMVC (as that was requested but comes with CI4). Also ci-phpunit-test would not be a bad idea.

  2. added this to the milestone on Jun 7, 2016
  3. modified the milestones: , on Jul 5, 2016
  4. daN4cat commented on Aug 11, 2016

    @daN4cat
    Collaborator

    @jekkos bear in mind that the system language needs to be renamed from english to en. That step needs to be added everytime CI is upgraded.

  5. jekkos commented on Aug 11, 2016

    @jekkos
    MemberAuthor

    You're right I'm currently facing this issue.

  6. modified the milestones: , on Aug 11, 2016
  7. jekkos commented on Aug 12, 2016

    @jekkos
    MemberAuthor

    I have updated my grunt-script-link tags fork to use a ignorePath property instead of absolutePath (as seen in wiredep plugni). After pushing that change I realised that current package.json depends on the master HEAD so when updating npm the build might break.

    I'll add the commit hash to the package.json to keep the old plugin version for now until I migrate to the newer version (or merge the composer branch)

  8. daN4cat commented on Aug 12, 2016

    @daN4cat
    Collaborator

    @jekkos your change is now causing a problem with the paths, for instance if I run grunt I get in login.php:

    <link rel="stylesheet" type="text/css" href="../../dist/login.css"/>

    instead of:

    <link rel="stylesheet" type="text/css" href="dist/login.css"/>

  9. jekkos commented on Aug 12, 2016

    @jekkos
    MemberAuthor

    OK that what I wanted to warn for.. doni't update npm modules (yet). The fix would be to change the #master of the plugin to a fixed commit number that has the absolutePath option change. Try to change #master with #c87d3e1dc8c2acf46e9b0712edc5ee7dc341eba1 in package.json for the grunt-script-link-tag dependency or a shorter version of this hash and rebuild?

  10. 117 remaining items

  11. daN4cat commented on Oct 2, 2016

    @daN4cat
    Collaborator

    OK, I see for the license point:

            clean: {
                license: ['bower_components/**/bower.json']
            }
    

    it's missing public/bower_components

  12. jekkos commented on Oct 2, 2016

    @jekkos
    MemberAuthor

    I did a global composer install on my system. I guess the grunt-composer will enable us to call composer through grunt.. but I'm not sure whether it will install it as well. As we're committing all of composer dependencies directly to the repo we might not need it directly so it might be only for convenience (call specific composer functions after calling grunt)

  13. daN4cat commented on Oct 2, 2016

    @daN4cat
    Collaborator

    I tested and language and the rest work fine, including the invoice emailing, the table js fix and etc.
    But the debug mode doesn't work well. I don't have time now to check that. Maybe later.

  14. jekkos commented on Oct 2, 2016

    @jekkos
    MemberAuthor

    Problem with debug mode is that js and css folders arent directly accessible from the public directory. I fixed this temporarily by symlinking these folders into public in docker, however that doesn't solve the issue on native installs.

    It might be better to move js/ and css/ to public/ folder permanently and adapt the Gruntfile with their new location.

  15. jekkos commented on Oct 2, 2016

    @jekkos
    MemberAuthor

    I'll look into that later today or tomorrow. I have also updated the translations with latest 3.1 version from CI repository. Should be all fine now indeed.

  16. daN4cat commented on Oct 6, 2016

    @daN4cat
    Collaborator

    I merged latest master into composer branch and then commited composer to master.

    This can be closed now because everything is in master.

    Let's wait for the "panic attack" of people asking what to do....

  17. odiea commented on Oct 6, 2016

    @odiea
    Collaborator

    The pull went just fine. The only thing you might add to the readme is the need to go to opensourcepos/public.

  18. daN4cat commented on Oct 6, 2016

    @daN4cat
    Collaborator

    Indeed

  19. jekkos commented on Oct 6, 2016

    @jekkos
    MemberAuthor

    Ok I fixed debug mode.. will push to master

  20. jekkos commented on Oct 6, 2016

    @jekkos
    MemberAuthor

    Thanks for the merge @daN4cat .. One bug left to check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions