Use prism for code syntax highlighting

This commit is contained in:
Oliver Davies 2017-03-16 08:09:52 +00:00
parent 356c9dca43
commit adf3c67355
54 changed files with 471 additions and 324 deletions

View file

@ -15,17 +15,23 @@ Earlier this year, I posted a solution to [an issue](http://drupal.org/node/7538
{% block content %}
To begin with, a download a fresh copy of Drupal 6.19 and created a copy of the original user.pages.inc file. Within the duplicate file, I made the same changes to the function that I did in earlier code, and saved the changes. Now, within my Terminal, I can navigate to Drupal's root directory and create the patch.
diff -rup modules/user/user.pages.inc modules/user/user.pages2.inc > /Users/oliver/Desktop/different_messages_for_blocked_users.patch
```language-bash
diff -rup modules/user/user.pages.inc modules/user/user.pages2.inc > /Users/oliver/Desktop/different_messages_for_blocked_users.patch
```
This command compares the differences between the two files, and creates the specified patch file.
To apply the patch to my Drupal installation, I go back to Terminal and run the following code:
patch -p0 < /Users/oliver/Desktop/different_messages_for_blocked_users.patch
```language-bash
patch -p0 < /Users/oliver/Desktop/different_messages_for_blocked_users.patch
```
If, for some reason, I need to reverse the patch, I can run this code:
patch -p0 -R < /Users/oliver/Desktop/different_messages_for_blocked_users.patch
```language-bash
patch -p0 -R < /Users/oliver/Desktop/different_messages_for_blocked_users.patch
```
And that's it!