Skip to main content

Questions tagged [version-control]

Use it for the management of changes to documents and other information stored as computer files.

Filter by
Sorted by
Tagged with
3 votes
1 answer
176 views

Is there a way to sync file naming across environments?

I have 3 environments with version control. Dev, staging and production. Now, say I create a new node in staging and create a corresponding file with the name: page--node--28.html.twig On production ...
seventh_sniper's user avatar
1 vote
0 answers
149 views

How to generate a patch from a merge request prior to rebase in GitLab?

I was using this core patch by taking the GitLab URL and adding .patch: https://git.drupalcode.org/project/drupal/-/merge_requests/2794.patch However, on June 16, the MR was rebased from 10.1 to 11.x. ...
Patrick Kenny's user avatar
0 votes
1 answer
61 views

How do I handle git asking me to remove untouched files?

A while ago, I cloned the Drupal repo. Today, I attempted a pull only to find out that I'm being asked to remove most, if not all, of the core directory to prevent overwriting. This happened to me ...
Kartagis's user avatar
  • 610
0 votes
1 answer
135 views

How can I collaborate with multiple developers? [closed]

I am developing a website on Drupal with 2 other developers. What would be the best way to collaborate? We plan to work on different git branches and there will be a dev and production branch as well. ...
ABHISHEK Joshi's user avatar
0 votes
0 answers
121 views

How to version control with Git whilst using composer?

So I've been going through the steep learning curve from D7 to D9. I like to use git for deployment and version control. I'm new to composer as I only know Drupal and it was never used. I've developed ...
gMaximus's user avatar
3 votes
1 answer
221 views

I'm trying to release a contrib module, but only see the dev version

I created an 8.x version of a contrib module I own (https://www.drupal.org/project/node_usage). It has a branch (8.x-1.x) and tag (8.x-1.0) and added the release, but the only 8.x one I see is 8.x-1.x-...
pglatz's user avatar
  • 469
0 votes
1 answer
39 views

Where do source trees for different versions of contrib modules reside?

I made a contrib module that has a 7.x version. I just created an 8.x version. Do I create a branch within the existing 7.x version for the new code, or create a separate version for the 8.x? If they ...
pglatz's user avatar
  • 469
0 votes
1 answer
276 views

Including modules in Git repository [duplicate]

Non core third party modules are maintained in modules directory in the Drupal root directory. Should this directory be added to the .gitignore file? If a module is upgraded in a Staging system then ...
mazman's user avatar
  • 3
1 vote
1 answer
38 views

What's the difference between creating a multisite vs development and production site? [closed]

Can I set up a multisite to perform the dev, production site, and eventually deployment ? Are they the same?
user avatar
2 votes
1 answer
979 views

How target specific version of fork based merge request (MR) patch

I'm upgrading the core from 9.1.7 to 9.2.5, however there's a patch I don't how to upgrade. This is the relative issue. The file 2897638-48.patch is currently used. The patch's work meanwhile proceed ...
Giuseppe's user avatar
  • 971
0 votes
1 answer
113 views

What are the steps for rebasing an issue fork of core to the latest code plus 'patch'?

It appears the current version of Drupal outside the issue fork needs to be added as a remote repository, but i'm getting tripped up on creating it as a branch i can rebase against. Hoping the answer ...
mlncn's user avatar
  • 1,482
1 vote
1 answer
90 views

When there is a Drupal.org issue with patches on it already what is the best (most polite, easiest, most technically sound) way to make a GitLab fork?

Scenario: There is an issue with a patch. Perhaps the patch edits a module's composer.json for Drupal 9 compatibility such that the recommended way to use the patch is as an issue fork. What is the ...
mlncn's user avatar
  • 1,482
0 votes
0 answers
72 views

With sites/default/files not part of the git repo, which content will be used in dev?

I am using a composer managed Drupal install and want to use git to move it between development and production environments. From what I understand, the only directory that is not supposed to be in ...
Extect's user avatar
  • 109
1 vote
1 answer
157 views

How to apply patches that are created in core-dev

Noob here. I'm trying to apply patches to my website, but it's keeps skipping because the version of the patch is for DEV. For example, I want to apply a patch to Core like this issue: https://www....
user avatar
0 votes
1 answer
50 views

How do I spawn additional instances with the same configuration?

I have the following scenario: I will develop an application based on Drupal. Everything will be developed on a local instance. Composer files, configuration and so on will be kept in a git repository....
flauschi's user avatar
0 votes
1 answer
2k views

Composer downgrading module version

I wish to move the bootstrap theme from the repository located in the folder theme/custom to be a dependency in composer.json I've checked that the current version drupal/bootstrap is 3.16 I perform ...
Oleksii Bondarenko's user avatar
8 votes
1 answer
223 views

How do I create a merge request for a project?

I'd like to create a merge request for a drupal.org project. I found a page on drupal.org titled Issue forks & merge requests which seems to address this but I'm not really getting anywhere. The ...
quant's user avatar
  • 556
0 votes
1 answer
50 views

Import images after git clone

So I did a git clone to get my Drupal 8 site working locally on another PC. This project already has a lot of nodes (articles) with images attached to them. The site works perfect, but of course I did ...
LennertSk's user avatar
4 votes
1 answer
4k views

How to install a specifc commit in Composer

The commerce_webform_order module (currently in dev status) recently changed one of its dependencies from Webform 5.x (stable) to Webform 6.x (alpha). I want to temporarily freeze ...
Vilāsamuni's user avatar
1 vote
0 answers
40 views

What are best practices for backing up settings files?

I have a Drupal 8 multisite with a few different hosts for production, staging, and local dev. Certain important files like settings.php and .htaccess are excluded from git, making it complicated to ...
pglatz's user avatar
  • 469
5 votes
1 answer
871 views

[user-name]@git.drupal.org: Permission denied (publickey)

I am trying to use git.drupal.org without success... I have uploaded my public key in the SSH keystab under my profile I have checked that the fingerprint on Drupal match my fingerprint in .ssh/...
Baud's user avatar
  • 542
1 vote
2 answers
203 views

How can I change the default branch of a contributed module?

If you're more used to GitLab than Drupal.org, you might spend a while hunting through settings there to figure out how to change the default branch - or concluding that you simply can't.
Kay V's user avatar
  • 648
0 votes
0 answers
38 views

Rebuild a site from a Git repo [duplicate]

We have a Standard Drupal site with lots of custom configurations ad custom modules. We would like to put this in a GitHub repository so that anyone can clone this repository and install the Drupal 8 ...
ktrev's user avatar
  • 139
1 vote
2 answers
2k views

Don't re-apply patches when requiring new module?

I keep running into the issue that, when requiring a new module with composer, existing packages are removed and reinstalled if they have patches defined in composer.json. For instance: $ lando ...
Mrweiner's user avatar
  • 1,921
0 votes
1 answer
60 views

How to generate my own patches to update core for security when fuerstnet.de's "Drupal upgrade the easy way" page is out of date?

For Drupal 7, under the current host I'm using (which doesn't provide things like drush), I've found that patching is the easiest approach to updating core. However, the commonly-referenced page which ...
koyae's user avatar
  • 181
0 votes
1 answer
600 views

How to apply a patch file in composer to a submodule of a module?

I've added the patch to composer.json like this: "drupal/admin_toolbar_tools": { "Bring back media to dropdown menu": "https://www.drupal.org/files/issues/2019-01-16/admin_toolbar-media_link-...
mana's user avatar
  • 403
0 votes
1 answer
1k views

Unable to apply patch

I am unable to apply patch using composer in Drupal core 8.6.4. Can anyone help me to apply patch using composer? Here is the process what I am doing : { "name": "drupal/drupal", "description": "...
Balbeer Yadav's user avatar
2 votes
0 answers
129 views

Create a patch for core.libraries.yml

I noticed that core/jquery.cookie is referencing the jquery-cookie v1.4.1 library that is now no longer maintained. It is being superseded by js-cookie and so I would like to write a Drupal core patch ...
usernameabc's user avatar
  • 2,726
1 vote
1 answer
755 views

Handling directory error with submitted patch [closed]

Drupal 8.x MAC OSX + Vagrant 2.2.0 How can I trace/define a directory error while trying to apply a Drupal.org patch? I have a patch submitted to a Drupal project module, and while trying to apply ...
Prestosaurus's user avatar
  • 2,067
9 votes
1 answer
3k views

`composer require` fails because "Source directory docroot/core has uncommitted changes"

Symptom: You have a script that fails while executing a composer require command, resulting in output like the following: $ ./example.sh Gathering patches for root package. Removing package drupal/...
TravisCarden's user avatar
0 votes
2 answers
124 views

Should modules be in source code management?

I am new to Drupal and I am using Drupal 7.61. Should the Drupal modules folder be git ignored or included in the source code management for best practices and continuous integration sake?
Moses Liao GZ's user avatar
0 votes
1 answer
107 views

How to associate multiple profiles per user with Profile2

I'm running a Drupal 7 site that has different profile types (created using the Profile2 module). Each user is associated with a profile, so at the time of registration, a potential user can choose a ...
DamianFox's user avatar
  • 113
0 votes
1 answer
2k views

Problem with .gitignore

I installed Drupal on ubuntu 16.04 via composer and I'm trying to implement continuous integration with Jenkins. So, I would like to be able to work from another location (for example from a Windows ...
Alessio Frabotta's user avatar
-1 votes
2 answers
401 views

Create a setting.*.php file for every stage of the website

I understand that my question could be opition-based and that it depends on the comfort of every drupal developer so please do not flag it as so ! For every Drupal 8 website i start, i use the below ...
Elie Masaad's user avatar
1 vote
1 answer
2k views

How to resolve File to Patch issue?

We are trying to apply a patch to a core module using Applying patches after updating Drupal core to 8.5.6. When running patch -p1 < patchname-issuenum-version.patch command, we get the following. ...
usernameabc's user avatar
  • 2,726
9 votes
4 answers
5k views

How to tell if my Drupal site is comprised from the SA-CORE-2018-002 -- 2018 March exploit?

Just released exploit: https://www.drupal.org/sa-core-2018-002 --- Drupal core - Highly critical - Remote Code Execution - SA-CORE-2018-002 How can I tell if someone used this exploit to hack my site?...
Patoshi パトシ's user avatar
0 votes
2 answers
464 views

How to properly perform a patch so that the correct directory is used?

I attempted to make a patch using Making a Drupal patch with Git and ran into one issue after creating the patch. For some reason, I cannot get the proper location to be stored in the patch. How can ...
usernameabc's user avatar
  • 2,726
0 votes
1 answer
111 views

How to read testbot feedback / get more info

I have created a patch for migrate_spreadsheet, unfortunately it will not pass the testbot. Instead that gives me this (to me cryptic / uninformative) message: fail: [run-tests.sh check] Line 0 of :...
firfin's user avatar
  • 250
13 votes
3 answers
34k views

How do I apply a patch with Composer workflow?

I need to include a patch in my project. I have included cweagans/composer-patches in composer.json and added the following lines in the extra section (example is from when trying to enable ...
Thomas Pappas's user avatar
1 vote
2 answers
1k views

Why is my Pantheon git clone not loading correctly?

My website is on Pantheon. I am using linux ubuntu 17.10 and LAMP for local development. I use the git clone command and it works. My drupal 8 files are there. Then I export and import the database ...
Olympus's user avatar
  • 93
20 votes
4 answers
6k views

Should I ignore the "vendor" directory?

I'm finally trying to get on board with using Drupal 8 and want to know if I should ignore the vendor directory in git with .gitignore. I would assume not, but I've seen a few example .gitignore files ...
Christia's user avatar
  • 1,667
1 vote
2 answers
863 views

Patching .htaccess file

I need to patch .htaccess file which is located in project's root (docroot in this case), my project is written using composer and I created a patch using git, added it to the /patches directory and ...
Viktor's user avatar
  • 319
1 vote
2 answers
671 views

What parts go under source code version control?

I am wondering what the best practices are for putting Drupal code under version control. I'll be mostly using core and standard Drupal modules. I'll be developing a custom theme, and one or two ...
Gaurav Sharma's user avatar
1 vote
1 answer
1k views

How do I use Git when using Composer?

I am working on an OpenSocial project and its installed via composer. I am having a folder structure as below: composer.json composer.lock html (Drupal Installation.) vendor (Dependencies) When ...
esafwan's user avatar
  • 1,348
0 votes
1 answer
29 views

Core patching and version controlling across multiple versions of the same site

How can I propagate core updates from an installation of a Drupal site to other installations of the same site? I maintain a private Drupal site which the owners now want to make public. As a result, ...
sisko's user avatar
  • 1,720
0 votes
1 answer
30 views

Put blocks, views, etc in git for other developers

Keep in mind that I'm fairly inexperienced with drupal! I use a docker based setup for my development environment for docker 7. I'm building a site that involves a front page that will be changed ...
SLOBY's user avatar
  • 103
0 votes
1 answer
1k views

How to apply .diff and .patch file by SSH? [closed]

I use Drupal 7 and I read every article about applying patches, but I don't understand how to apply patches to Drupal files using SSH. I am administrator of a Linux server that hosts a Drupal site. ...
omiti's user avatar
  • 145
4 votes
2 answers
4k views

How do I use a settings.local.php file?

I couldn't find answer from previous questions nor drupal.org/pantheon.io. There isn't a settings.php if I clone the repository from pantheon.io nor a settings.local.php. If I create a settings.local....
user1271930's user avatar
0 votes
1 answer
66 views

Featurize user roles and permissions can't update

I have added user roles and permissions to feature which I use to featurize general site configurations and theme settings. In the past I believe this worked just fine, however, with my latest push ...
Christia's user avatar
  • 1,667
1 vote
1 answer
908 views

Error applying patch with Git

I have read different SE posts and Drupal.org posts about applying patches using git but I am getting an error message whenever I try any of the following methods. the error is: error: modules/...
Christia's user avatar
  • 1,667

1
2 3 4 5 6