Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Matt Andrade
    @andrade1379

    Hey guys, was wondering how one would be able to require multiple Drupal modules at once?

    composer require drupal/<module1> drupal/<module2> drupal/<module3>

    OR

    composer require drupal/<module1> <module2> <module3>
    Romain GRELET
    @babaorum
    the first one will work, i do not think the second one will
    Matt Andrade
    @andrade1379
    @babaorum you’re correct
    Karl Viiburg
    @kurbar

    Hi, am I able to somehow have two different sets of repositories based on some env?

    I'm developing a modular app and I'm loading in different modules through Composer.

    For development purposes I use local symlinked copies but for deployments I want to have VCS repositories for those. Changing the files back and forth is quite tedious so I was wondering if there is a way I can make it easier.

    Stavros Kefaleas
    @skiabox
    hello!
    I get the following error
    ➜  ~/Sites/PhpProject3 php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
    PHP Warning:  copy(https://getcomposer.org/installer): failed to open stream: Host is down in Command line code on line 1
    
    Warning: copy(https://getcomposer.org/installer): failed to open stream: Host is down in Command line code on line 1
    Stavros Kefaleas
    @skiabox
    problem solved
    it was a little snitch signature problem
    little snitch is the most popular mac os firewall
    Alex K
    @alex-enchi
    Hi, I have a weird question. Currently I am working with application without composer and because of many reason we can't install one, at least now. Is there any way to bundle composer library, like this https://github.com/wapmorgan/MediaFile with dependencies into one bundle? If so where I can read about it
    Thanks
    Christian Sciberras
    @uuf6429
    @alex-enchi you don't need composer after you get your dependencies... just create a composer.json file with the dependencies you want, run composer install and then use/copy the resulting vendor directory.
    Alex K
    @alex-enchi
    @uuf6429 do I need to still use autoload.php?
    Christian Sciberras
    @uuf6429
    Correct
    Alex K
    @alex-enchi
    Thank you
    Christian Sciberras
    @uuf6429
    Note that you won't need the composer.json/lock files afterwords, but I would still save them somewhere.
    Alex K
    @alex-enchi
    I'll definitely keep them under git, my main concern was that it's impossible to have composer installed and ran on target machines, only on local dev environment.
    Christian Sciberras
    @uuf6429
    The general recommendation is that you do not run composer in production. What we did at my previous company is to have build machines whose environment is identical to production. These machines would create a standalone release package that is tested and then used in production. Nowadays, one could use docker images for the same purpose, I suppose.
    Alex K
    @alex-enchi
    We're not there yet and dealing with a lot of legacy, but slowly moving forward. Hope it'll work out smoothly.
    Thanks for clarification
    Jochen Manz
    @jochenmanz
    Hi! I just noticed a strange new behaviour with 1.7.3 related to the "replace tag" change. I do have a repo which requires symfony/symfony: "3.4.18". I am not able to require a newer version of symfony/serializer (4.1 in my case) because symfony/symfony has a replace set for same.version. Is this a known bug or even known and good behaviour? It works with 1.7.2 and lower
    ok, found a issue about that: composer/composer#7764 seems like we have to change our way :D
    Stavros Kefaleas
    @skiabox
    hello guys
    I am getting class not found error
    when I try to use a 3rd party library using composer
    any ideas?
    Ben Johnson
    @cbj4074
    @skiabox It would help to see the actual error message...
    (and the require statement you used to add the dependency)
    xicond
    @xicond
    is there a way to specify different name for composer.lock ?
    Phiter Fernandes
    @phiter
    hey guys
    I have a custom composer script that generates a file, and this command has an argument
    After the file is created, I have to run chmod too, so I have this
    "create" : [
                "@phinx create --template=MigrationTemplate.php.dist",
                "@unlock"
            ],
    whatever argument I pass to create is passed tothe first function but also to the @unlock one, which is the one that runs chmod
    is there a way to make it not pass the argument to @unlock?
    Phiter Fernandes
    @phiter
    Ok I found a way to ignore it
    "create" : [
                "@phinx create --template=MigrationTemplate.php.dist",
                "@unlock"
            ],
            "unlock" : "chmod -R 777 db/migrations && :",
    I put && colon after the chmod so anything after it is ignored
    Ben Johnson
    @cbj4074
    @phiterf That's a creative solution. Thanks for sharing. :) That behavior seems odd in the first place.
    ashashingadia2996
    @ashashingadia2996
    I want to install my local package using composer, I have tried solutions found from the web and didn't get desired results. Can anyone please suggest me steps for that. Any help would be appreciated :)
    Ben Johnson
    @cbj4074
    @ashashingadia2996 What, exactly, have you tried so far? It would be helpful to know what you tried so we know why it didn't work.
    megri
    @megri
    I am using a lib jms/serializer that uses annotations from doctrine. For the annotations to be workable it seems I am required to add Doctrine\Common\Annotations\AnnotationRegistry::registerLoader('class_exists'); at the start of my project. I'm thinking it'd be nice if I could somehow incorporate this into the generated autoload.php-file, so that it's always called exactly once without me having to spell it out all over the place. Is this somehow possible?
    Pierre-Emmanuel Lallemant
    @pelallemant
    Hi. I'm using curl -s https://getcomposer.org/installer | php to install composer, and I now have tons of warnings about deprecation of package names which doesn't match a certain pattern. My question is: when the 2.0 will be available, will it be installed by my last command ? And is there any information about the 2.0 release, will it make the 1.X composer down, or will packagist still be working with older versions of composer ? It would be nice that there would be an installer for the 1.X and another installer for the 2.X . By doing this, projects deployed in CI/CD using this installer would not fetch by error the 2.X (which could crash if package names aren't valid)
    Ben Johnson
    @cbj4074
    @megri Didn't see your question from so long ago, but if I understand it correctly, you can simply do as I describe here: https://stackoverflow.com/a/55339202/1772379
    Doqnach
    @Doqnach
    any idea when composer:1.8.5 will be on docker-hub? since 1.8.4 gives CVE warnings because of the git version (alpine 3.8 based)
    Ricardo Murillo
    @ricardowall13_twitter
    I think if you can blindly trust other parties to have your infrastructure and centralize it for the whole network, then a blockchain is not what you need.
    See this thinking here
    https://medium.com/worldsibu/forma-they-way-youve-wished-enterprise-blockchain-infrastructure-was-61f470fcbc78
    Doqnach
    @Doqnach
    hey all, anyone any idea how to get event data in a composer script if it's a bash script?
    @everyone
    UniFreak
    @UniFreak
    Hi, I’m trying to install a private hosted package, by running the command composer require mycompany/qlog
    but the result keeps error out due to unmet dependencies of elastiquent/elasticquent