Skip to content

Instantly share code, notes, and snippets.

@mparker17
Last active March 20, 2019 17:58
Show Gist options
  • Save mparker17/e535b85888f54d5eb3a712d174052fb2 to your computer and use it in GitHub Desktop.
Save mparker17/e535b85888f54d5eb3a712d174052fb2 to your computer and use it in GitHub Desktop.
Updating Pressflow/Drops
#!/bin/bash
#
# @file
# Update pressflow/6.
#
# Some variables to start off with.
export my_fork_clone_url='https://github.com/mparker17/6'
export patch_id='SA-CORE-2019-002'
# The actual script.
git clone --recursive $my_fork_clone_url pressflow6
git clone --recursive https://git.drupal.org/project/d6lts.git d6lts
cd pressflow6 || exit 1
git checkout master
git remote add upstream https://github.com/pressflow/6.git
git fetch --all -t -p
git merge upstream/master
git push origin master
git checkout -b "$patch_id"
git apply --index "../d6lts/common/core/$patch_id.patch"
git commit -m "Apply the changes from D6LTS $patch_id."
git push --set-upstream origin "$patch_id"
#!/bin/bash
#
# @file
# Update pressflow/7.
#
# Some variables to start off with.
export my_fork_clone_url='https://github.com/mparker17/7'
export new_version='7.65'
# The actual script.
git clone --recursive $my_fork_clone_url pressflow7
cd pressflow7 || exit 1
git checkout master
git remote add upstream https://github.com/pressflow/7.git
git remote add drupal https://git.drupal.org/project/drupal.git
git fetch --all -t -p
git merge upstream/master
git push origin master
git checkout -b "pressflow-$new_version"
git merge "$new_version"
git push --set-upstream origin "pressflow-$new_version"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment