composer.json for a WordPress Child Theme

1

I will try to explain my problem as well as possible. I want that when I install a WordPress theme that depends on another (that's what I want to install is a Child Theme), the parent theme will be downloaded automatically.

In the file composer.json I have the following:

{
    "name": "rogertm/themingisprose",
    "description": "Twenty'em Child Theme",
    "keywords": ["wordpress", "framework", "child theme"],
    "homepage": "https://themingisprose.com",
    "license": "GPL-2.0-or-later",
    "minimum-stability": "stable",
    "type": "wordpress-theme",
    "require": {
        "php": ">=7.0",
        "composer/installers": "^1.0",
        "rogertm/twenty-em": "1.2.*"
    },
    "authors": [
        {
            "name": "RogerTM",
            "email": "[email protected]",
            "homepage": "https://themingisprose.com",
            "role": "Developer"
        }
    ]
}

If I removed the line "rogertm/twenty-em": "1.2.*" works perfectly, the theme is installed in the directory wp-content/themes/ without problems, but in this case I get an error:

  

Your requirements could not be resolved to an installable set of   packages.

     

Problem 1

     
  • Installation request for rogertm / themingisprose dev-master - > satisfiable by rogertm / themingisprose [dev-master].
  •   
  • rogertm / themingisprose dev-master requires rogertm / twenty-em 1.2. * - > no matching package found.
  •   

Potential causes:

     
  • A typo in the package name
  •   
  • The package is not available in a stable-enough version according to your minimum-stability setting see    link for more   details.
  •   

If I install the parent theme (framework) directly it does not present any problem, you can see the file composer .json ...

What am I doing wrong? Thanks in advance ...

    
asked by Roger TM 07.02.2018 в 20:41
source

0 answers