Skip to content

Instantly share code, notes, and snippets.

View mattgibson's full-sized avatar

Matt Gibson mattgibson

View GitHub Profile
@mattgibson
mattgibson / min_3773
Last active December 16, 2020 15:24
For QA of MIN-3773
id
186487
@mattgibson
mattgibson / tddium.rake
Last active August 29, 2015 14:13
Post deploy hook to push a Rails app from Solano Labs (Tddium) to AWS OpsWorks if the CI build is successful
# To set up:
#
# Add this file to /lib/tasks/tddium.rake
#
# Create an IAM user on AWS with no special policies, then add the access
# key and secret key to your Tddium suite config like this:
#
# cd /your/local/app/directory
# tddium config:add suite AWS_ACCESS_KEY yourkeyhere
# tddium config:add suite AWS_SECRET_KEY yoursecrethere
@mattgibson
mattgibson / basic_cucumber_scenario.feature
Last active August 29, 2015 14:11
Basic Moodle Cucumber scenario
Scenario: Navigating to the new activity form
Given I am on the course page
When I click on the new activity button
And I enter the details of a new activity and save the form
Then I should be on the page for the new activity
And I should see the details of the new activity on the page
@mattgibson
mattgibson / keybase.md
Last active August 29, 2015 14:06
keybase.md

Keybase proof

I hereby claim:

  • I am mattgibson on github.
  • I am mattgibson (https://keybase.io/mattgibson) on keybase.
  • I have a public key whose fingerprint is 3050 E6FB 37F1 6961 B66B 1F17 B221 45D2 23E2 C2FD

To claim this, I am signing this object:

@mattgibson
mattgibson / tddium.rake
Created November 15, 2012 12:11 — forked from wkrsz/gist:2761871
Tddium post-build-hook to deploy to EngineYard
# Setup:
# tddium config:add suite EY_API_TOKEN xxxxxxxx
# (take EY_API_TOKEN value from ~/.eyrc)
# tddium config:add suite EY_DEPLOY_KEY yyyyyyy
# (EY_DEPLOY_KEY value is Base64-encoded content of your ~/.ssh/id_rsa OR any other ssh key authorised for a given EY env)
# To get a new key: $ ssh-keygen -t rsa
# To base 64 encode it without line breaks and copy to the clipboard: $ openssl base64 < ey-key | tr -d '\n' | pbcopy
# Now add the public key to Engine Yard via the GUI, * AND APPLY CHANGES TO THE ENVIRONMENT *
#
# Be aware that the command line tddium thing will connect to the remote suite based on the name of the local
@mattgibson
mattgibson / gist:2936227
Created June 15, 2012 12:29
Shell command to zip a moodle block into a release
# To be run from within the block folder
git archive -o ../block_ajax_marking-2.1.5b3.zip --prefix=ajax_marking/ MOODLE_22_STABLE
# Changelog URL for the plugins DB GUI
https://github.com/mattgibson/moodle-block_ajax_marking/commits/MOODLE_22_STABLE
# Alternative download URL for the plugins DB GUI
https://github.com/mattgibson/moodle-block_ajax_marking/zipball/2.1.5b4
@mattgibson
mattgibson / gist:2875045
Created June 5, 2012 13:36
Copying a distinct feature or hotfix branch from one release branch to another
# Example scenario: two Moodles - one 2.1.x, one 2.2.x. Fix is on 2.2.x and we want to backport it
# to 2.1.x. Each moodle is a separate repo roughly following the gitflow approach and there is a
# separate develop and release branch for each one.
# Push to gihub from the repo that has the fix branch
# Fetch from github from the repo that needs it (assuming we have one repo for each release branch)
# Checkout the fix branch as a new local branch
git checkout -b localfix origin/fixbranch
@mattgibson
mattgibson / gist:2638241
Created May 8, 2012 18:25
Debuggable query for the AJAX Marking block
if ($CFG->debug == DEBUG_DEVELOPER) {
$debugquery = block_ajax_marking_debuggable_query($sql, $params);
}