backdrop-contrib / project

Projects associate a code-based project with releases and power the update server of BackdropCMS.org
2 stars 10 forks source link

Add back missing Drupal git history #45

Open jenlampton opened 4 years ago

jenlampton commented 4 years ago

When checking to see which Drupal 7 version of this module we started with, I realized that the Drupal git history was not maintained.

The first commit to this project is

commit 30e052492d4a0a5988c4d0438e95c7af2913bca0
Author: Nathan Haug <nate@lullabot.com>
Date:   Thu Mar 26 12:58:34 2015 -0700

    Initial port of BackdropCMS port.
jenlampton commented 4 years ago

We started this project on Thursday March 26th, 2015. Nearest releases are as follows:

The most recent commit to the -dev version (I'm going to assume Nate started from the -dev version) before March 26th, was this one:

commit a212bfbe9bf8f87cc12e45dde0f164b7a0bf9341
Author: formatCvt <formatCvt@1853874.no-reply.drupal.org>
Date:   Sun Feb 15 21:10:33 2015 -0800

    Issue #2398861 by formatC'vt: Fix empty project usage table

This changed

$usage_week_nids = db_query('SELECT DISTINCT(nid) FROM {project_usage_week_project}')->fetchCol();
$query = db_select('node', 'n')

to

$usage_week_nids = db_query('SELECT DISTINCT(nid) FROM {project_usage_week_project}')->fetchCol();
if (!empty($usage_week_nids)) {

Here's what we have:

$usage_week_nids = db_query('SELECT DISTINCT(nid) FROM {project_usage_week_project}')->fetchCol();
if (!empty($usage_week_nids)) {

So I'm pretty sure we started from commit a212bfbe9bf8f87cc12e45dde0f164b7a0bf9341.

jenlampton commented 4 years ago

Well, I tried to do it with a merge and with a rebase, but I cannot figure out how to get a repository that contains the old Drupal git history before Thursday March 26th, 2015, and the new Backdrop git history from after.

I think the problem is that there's a significant change between the ending-Drupal commit and the starting-Backdrop commit, and Git needs to know how to make that jump in order to merge the two histories.

I don't have time for this today, but would love to get it sorted eventually :)

herbdool commented 4 years ago

The one way I was able to get both histories together is by using git pull --allow-unrelated-histories -s ours d7 7.x-2.0-alpha1. The downside is that it puts the Drupal history after the current Backdrop history, but at least it's there and it keeps the latest BD code the same, as far as I can tell. (I had added the Drupal project as a remote repo and named it d7).