How to add theme from github with composerHow can I include a third party library in my custom module without using Composer ManagerWhere and how should I use Composer and the drupal-composer/drupal-project scaffold to install the required libraries?Installing Bootstrap theme using ComposerIs Composer incapable of updating a project that has already been installed from the .zip distribution?how to import library from Github when the installed module in Drupal 8How do I use composer with modules?Installing a site with composerDrupal install with composer (drupal-project)Can I remove dependencies from dependencies via composer?Support composer_manager AND drupal-composer/drupal-project with contrib module
Is this Paypal Github SDK reference really a dangerous site?
Too soon for a plot twist?
Sort array by month and year
How to recover against Snake as a heavyweight character?
What is the purpose of a disclaimer like "this is not legal advice"?
ESPP--any reason not to go all in?
How to make sure I'm assertive enough in contact with subordinates?
Can I negotiate a patent idea for a raise, under French law?
Why aren't there more Gauls like Obelix?
Having the player face themselves after the mid-game
Has a sovereign Communist government ever run, and conceded loss, on a fair election?
Why restrict private health insurance?
What is Tony Stark injecting into himself in Iron Man 3?
Why does a car's steering wheel get lighter with increasing speed
Did Amazon pay $0 in taxes last year?
Does an unused member variable take up memory?
Boss Telling direct supervisor I snitched
What does *dead* mean in *What do you mean, dead?*?
Unidentified signals on FT8 frequencies
How spaceships determine each other's mass in space?
How to write a chaotic neutral protagonist and prevent my readers from thinking they are evil?
What is the oldest European royal house?
How would an energy-based "projectile" blow up a spaceship?
An Undercover Army
How to add theme from github with composer
How can I include a third party library in my custom module without using Composer ManagerWhere and how should I use Composer and the drupal-composer/drupal-project scaffold to install the required libraries?Installing Bootstrap theme using ComposerIs Composer incapable of updating a project that has already been installed from the .zip distribution?how to import library from Github when the installed module in Drupal 8How do I use composer with modules?Installing a site with composerDrupal install with composer (drupal-project)Can I remove dependencies from dependencies via composer?Support composer_manager AND drupal-composer/drupal-project with contrib module
I have a Drupal 8 installation and I like to install a theme from github.com using composer.
It is this theme https://github.com/forumone/gesso
Can anybody help me what I have to add to the composer.json and where?
8 installing composer
add a comment |
I have a Drupal 8 installation and I like to install a theme from github.com using composer.
It is this theme https://github.com/forumone/gesso
Can anybody help me what I have to add to the composer.json and where?
8 installing composer
add a comment |
I have a Drupal 8 installation and I like to install a theme from github.com using composer.
It is this theme https://github.com/forumone/gesso
Can anybody help me what I have to add to the composer.json and where?
8 installing composer
I have a Drupal 8 installation and I like to install a theme from github.com using composer.
It is this theme https://github.com/forumone/gesso
Can anybody help me what I have to add to the composer.json and where?
8 installing composer
8 installing composer
edited 13 hours ago
kiamlaluno♦
80.5k9132249
80.5k9132249
asked 13 hours ago
lesley n.lesley n.
3561418
3561418
add a comment |
add a comment |
3 Answers
3
active
oldest
votes
If you still want download theme from github, you can edit file composer.json by add more repository:
Add this code
"type": "package",
"package":
"name": "forumone/gesso",
"version": "2.0",
"type":"drupal-theme",
"source":
"url": "https://github.com/forumone/gesso.git",
"type": "git",
"reference": "8.x-2.x"
after
"type": "composer",
"url": "https://packages.drupal.org/8"
,
and run composer require "forumone/gesso"
to download theme and update composer.lock.
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could docomposer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.
– Kevin
11 hours ago
add a comment |
Adding this answer for more clarification for future readers:
The theme in question as of this comment date has a stable release from April 2018. But the development branch is active and updated.
In such a case, you would do this to fetch it instead of the latest stable:
composer require drupal/gesso:2.x-dev
To go even further, you can tack a commit sha on the end of the version to 'pin` the code at that commit - unless you want rolling updates from HEAD. This is a versatile option that you can opt for in Composer that is not so known in the Drupal circles.
You don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on drupal.org at all, 99% of the time they are on Packagist (third party packages, like Prophecy etc).
The rare case is when you have a private repo on GitHub/GitLab or elsewhere, then this is the approach you would want to take to fetch it.
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
add a comment |
You shouldn't use the Github repository, unless you're getting involved in the theme's development - it doesn't contain a composer.json file, so isn't supposed to be installed this way.
You could mess about trying to set it up as a custom repository, but given that this is a theme hosted on (and packaged by) drupal.org, it would be easier to just install it the standard way:
composer require drupal/gesso
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
1
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you havetype: drupal-module
if you want it to be moved into the correct folders etc when installing
– Clive♦
13 hours ago
2
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "220"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdrupal.stackexchange.com%2fquestions%2f277469%2fhow-to-add-theme-from-github-with-composer%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
If you still want download theme from github, you can edit file composer.json by add more repository:
Add this code
"type": "package",
"package":
"name": "forumone/gesso",
"version": "2.0",
"type":"drupal-theme",
"source":
"url": "https://github.com/forumone/gesso.git",
"type": "git",
"reference": "8.x-2.x"
after
"type": "composer",
"url": "https://packages.drupal.org/8"
,
and run composer require "forumone/gesso"
to download theme and update composer.lock.
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could docomposer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.
– Kevin
11 hours ago
add a comment |
If you still want download theme from github, you can edit file composer.json by add more repository:
Add this code
"type": "package",
"package":
"name": "forumone/gesso",
"version": "2.0",
"type":"drupal-theme",
"source":
"url": "https://github.com/forumone/gesso.git",
"type": "git",
"reference": "8.x-2.x"
after
"type": "composer",
"url": "https://packages.drupal.org/8"
,
and run composer require "forumone/gesso"
to download theme and update composer.lock.
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could docomposer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.
– Kevin
11 hours ago
add a comment |
If you still want download theme from github, you can edit file composer.json by add more repository:
Add this code
"type": "package",
"package":
"name": "forumone/gesso",
"version": "2.0",
"type":"drupal-theme",
"source":
"url": "https://github.com/forumone/gesso.git",
"type": "git",
"reference": "8.x-2.x"
after
"type": "composer",
"url": "https://packages.drupal.org/8"
,
and run composer require "forumone/gesso"
to download theme and update composer.lock.
If you still want download theme from github, you can edit file composer.json by add more repository:
Add this code
"type": "package",
"package":
"name": "forumone/gesso",
"version": "2.0",
"type":"drupal-theme",
"source":
"url": "https://github.com/forumone/gesso.git",
"type": "git",
"reference": "8.x-2.x"
after
"type": "composer",
"url": "https://packages.drupal.org/8"
,
and run composer require "forumone/gesso"
to download theme and update composer.lock.
answered 12 hours ago
JonhJonh
345120
345120
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could docomposer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.
– Kevin
11 hours ago
add a comment |
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could docomposer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.
– Kevin
11 hours ago
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could do
composer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.– Kevin
11 hours ago
Just to clarify here, the dev branch for this theme is parallel on both GitHub and drupal.org. Alternatively, one could do
composer require drupal/gesso:2.x-dev
to get the dev branch. To me it looks exactly the same. So, you don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on d.o. at all, 99% of the time they are on packagist (third party vendor). The rare case is when you have a private repo on GitHub, then this is the approach you would want to take.– Kevin
11 hours ago
add a comment |
Adding this answer for more clarification for future readers:
The theme in question as of this comment date has a stable release from April 2018. But the development branch is active and updated.
In such a case, you would do this to fetch it instead of the latest stable:
composer require drupal/gesso:2.x-dev
To go even further, you can tack a commit sha on the end of the version to 'pin` the code at that commit - unless you want rolling updates from HEAD. This is a versatile option that you can opt for in Composer that is not so known in the Drupal circles.
You don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on drupal.org at all, 99% of the time they are on Packagist (third party packages, like Prophecy etc).
The rare case is when you have a private repo on GitHub/GitLab or elsewhere, then this is the approach you would want to take to fetch it.
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
add a comment |
Adding this answer for more clarification for future readers:
The theme in question as of this comment date has a stable release from April 2018. But the development branch is active and updated.
In such a case, you would do this to fetch it instead of the latest stable:
composer require drupal/gesso:2.x-dev
To go even further, you can tack a commit sha on the end of the version to 'pin` the code at that commit - unless you want rolling updates from HEAD. This is a versatile option that you can opt for in Composer that is not so known in the Drupal circles.
You don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on drupal.org at all, 99% of the time they are on Packagist (third party packages, like Prophecy etc).
The rare case is when you have a private repo on GitHub/GitLab or elsewhere, then this is the approach you would want to take to fetch it.
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
add a comment |
Adding this answer for more clarification for future readers:
The theme in question as of this comment date has a stable release from April 2018. But the development branch is active and updated.
In such a case, you would do this to fetch it instead of the latest stable:
composer require drupal/gesso:2.x-dev
To go even further, you can tack a commit sha on the end of the version to 'pin` the code at that commit - unless you want rolling updates from HEAD. This is a versatile option that you can opt for in Composer that is not so known in the Drupal circles.
You don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on drupal.org at all, 99% of the time they are on Packagist (third party packages, like Prophecy etc).
The rare case is when you have a private repo on GitHub/GitLab or elsewhere, then this is the approach you would want to take to fetch it.
Adding this answer for more clarification for future readers:
The theme in question as of this comment date has a stable release from April 2018. But the development branch is active and updated.
In such a case, you would do this to fetch it instead of the latest stable:
composer require drupal/gesso:2.x-dev
To go even further, you can tack a commit sha on the end of the version to 'pin` the code at that commit - unless you want rolling updates from HEAD. This is a versatile option that you can opt for in Composer that is not so known in the Drupal circles.
You don't need to pull from GitHub in this instance. The only time you would want to do this is when a package does not live on drupal.org at all, 99% of the time they are on Packagist (third party packages, like Prophecy etc).
The rare case is when you have a private repo on GitHub/GitLab or elsewhere, then this is the approach you would want to take to fetch it.
answered 11 hours ago
KevinKevin
18.2k853113
18.2k853113
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
add a comment |
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
This is a good answer, because you give the advice of best practice. So I've learned a lot today. How to add package to composer.json and how to use dev-version with cli command.
– lesley n.
10 hours ago
add a comment |
You shouldn't use the Github repository, unless you're getting involved in the theme's development - it doesn't contain a composer.json file, so isn't supposed to be installed this way.
You could mess about trying to set it up as a custom repository, but given that this is a theme hosted on (and packaged by) drupal.org, it would be easier to just install it the standard way:
composer require drupal/gesso
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
1
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you havetype: drupal-module
if you want it to be moved into the correct folders etc when installing
– Clive♦
13 hours ago
2
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
add a comment |
You shouldn't use the Github repository, unless you're getting involved in the theme's development - it doesn't contain a composer.json file, so isn't supposed to be installed this way.
You could mess about trying to set it up as a custom repository, but given that this is a theme hosted on (and packaged by) drupal.org, it would be easier to just install it the standard way:
composer require drupal/gesso
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
1
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you havetype: drupal-module
if you want it to be moved into the correct folders etc when installing
– Clive♦
13 hours ago
2
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
add a comment |
You shouldn't use the Github repository, unless you're getting involved in the theme's development - it doesn't contain a composer.json file, so isn't supposed to be installed this way.
You could mess about trying to set it up as a custom repository, but given that this is a theme hosted on (and packaged by) drupal.org, it would be easier to just install it the standard way:
composer require drupal/gesso
You shouldn't use the Github repository, unless you're getting involved in the theme's development - it doesn't contain a composer.json file, so isn't supposed to be installed this way.
You could mess about trying to set it up as a custom repository, but given that this is a theme hosted on (and packaged by) drupal.org, it would be easier to just install it the standard way:
composer require drupal/gesso
answered 13 hours ago
Clive♦Clive
147k13250292
147k13250292
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
1
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you havetype: drupal-module
if you want it to be moved into the correct folders etc when installing
– Clive♦
13 hours ago
2
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
add a comment |
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
1
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you havetype: drupal-module
if you want it to be moved into the correct folders etc when installing
– Clive♦
13 hours ago
2
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
on drupal.org the files are from last year and on github from this year. That's why I want to install from github.
– lesley n.
13 hours ago
1
1
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
You would have to add the github repo as a new repository item and call it that way. It isn't ideal, and the Gesso theme should have updated its d.o. project as thats where everyone expects to obtain packages. getcomposer.org/doc/05-repositories.md
– Kevin
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you have
type: drupal-module
if you want it to be moved into the correct folders etc when installing– Clive♦
13 hours ago
What @Kevin said. And just to add that when code isn't in a stable branch, it's often because it's not considered to be stable. i.e. don't run it in production without a plenty of testing. You can find out how to add a custom github repository in the composer docs, just make sure you have
type: drupal-module
if you want it to be moved into the correct folders etc when installing– Clive♦
13 hours ago
2
2
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
@lesleyn. The development snapshot has been updated on February, 2019. If you want to know when the next official release will be made, you can check/ask on the theme issue queue, on drupal.org.
– kiamlaluno♦
13 hours ago
add a comment |
Thanks for contributing an answer to Drupal Answers!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdrupal.stackexchange.com%2fquestions%2f277469%2fhow-to-add-theme-from-github-with-composer%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown