Skip to content

Instantly share code, notes, and snippets.

View dan987's full-sized avatar

Dan M dan987

View GitHub Profile
@dan987
dan987 / newrelic_instrumenter.rb
Created July 12, 2018 14:46 — forked from nettofarah/newrelic_instrumenter.rb
sample newrelic instrumenter for graphql-ruby
# NewRelic instrumenter for GraphQL-ruby
#
# In your controller:
# ::NewRelic::Agent.add_custom_attributes({
# user_id: @user.try(:id),
# query_string: @query_string,
# query_arguments: @query_variables
# })
#
# @document = self.class.trace_execution_scoped(["GraphQL#parse"]) do
@dan987
dan987 / pr.md
Created August 6, 2014 14:26 — forked from piscisaureus/pr.md

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

# We created a folder to house our code for the class
mkdir code
# We changed into that directory
cd code
# We verified git was installed
which git
# After forking on github, we cloned OUR copy
git clone https://github.com/StevenNunez/BEWD_NYC_5.git
# We checked what folders are in our code folder. Cloning creates a folder named after the repository.
ls