Skip to content

Instantly share code, notes, and snippets.

@MichaelCurrin
MichaelCurrin / README.md
Last active April 14, 2024 16:26
GitHub GraphQL - Get Pull Requests using GH's GraphQL API

Get Pull Requests using GH's GraphQL API

How to get Pull Requests data using Github in the browser, or using the API to allow for automating reporting or building in values into a website.

Resources

@swalkinshaw
swalkinshaw / tutorial.md
Last active November 13, 2023 08:40
Designing a GraphQL API
@mileszs
mileszs / hiring.mkd
Last active October 14, 2018 20:22

How to Hire Developers

  1. Go to the events the type of developers you want to hire go to. Do this even when you aren't actively hiring.
  2. Try to sponsor or otherwise support the events/groups/newsletters/things the type of developers you want to hire like. Do this even when you aren't actually hiring.
  3. Favor smart people who fit your culture over resumés that check your requirements boxes.
  4. If you can't find enough examples of work to suffice, and must do a technical assessment, try to fashion a low-pressure one. Example: Make an empty private GitHub repo. Give them a task / thing to build and have them make it a pull request to that repo. If you aren't going to bring them in for an actual interview after they submit their homework, at least provide feedback on the pull request. If you are going to bring them in, chat with them about their homework, including talking casually about things they might do differently, or things they might add.

Why should you do 1 and 2 when you aren't hiring? You might

var pureRender = (Component) => {
Object.assign(Component.prototype, {
shouldComponentUpdate (nextProps, nextState) {
return !shallowEqual(this.props, nextProps) ||
!shallowEqual(this.state, nextState);
}
});
};
module.exports = pureRender;

###Create and checkout a new branch git checkout -b [branchName]

###Checkout a remote branch git checkout -b [localBranchName] origin/[remoteBranchName]

###Push local branch to remote git push -u origin [branchName]

###Delete remote branch

@jkubacki
jkubacki / gist:e2dd904bd648b0bd4554
Created January 21, 2015 18:47
Mac uninstall elasticsearch
#!/usr/bin/env sh
# checks to see if running
launchctl list | grep elasticsearch
launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.elasticsearch.plist
launchctl remove homebrew.mxcl.elasticsearch
pkill -f elasticsearch
@bendc
bendc / functional-utils.js
Last active September 15, 2023 12:12
A set of pure ES2015 functions aimed to make functional JavaScript more idiomatic.
// array utils
// =================================================================================================
const combine = (...arrays) => [].concat(...arrays);
const compact = arr => arr.filter(Boolean);
const contains = (() => Array.prototype.includes
? (arr, value) => arr.includes(value)
: (arr, value) => arr.some(el => el === value)
@DanHerbert
DanHerbert / fix-homebrew-npm.md
Last active February 12, 2024 17:18
Instructions on how to fix npm if you've installed Node through Homebrew on Mac OS X or Linuxbrew

OBSOLETE

This entire guide is based on an old version of Homebrew/Node and no longer applies. It was only ever intended to fix a specific error message which has since been fixed. I've kept it here for historical purposes, but it should no longer be used. Homebrew maintainers have fixed things and the options mentioned don't exist and won't work.

I still believe it is better to manually install npm separately since having a generic package manager maintain another package manager is a bad idea, but the instructions below don't explain how to do that.

Fixing npm On Mac OS X for Homebrew Users

Installing node through Homebrew can cause problems with npm for globally installed packages. To fix it quickly, use the solution below. An explanation is also included at the end of this document.