- Site Reliability Engineering: How Google Runs Production Systems
- Operating Systems
- Operating Systems: Three Easy Pieces
- How Linux Works, 2nd Edition
- Continuous Delivery: Reliable Software Releases through Build, Test, and Deployment Automation
- [Systems Performance: Enterprise and the Cloud](https://www.amazon.com/gp/product/0133390098?ie=UTF8&tag=deirdrestraug-20&linkCode=as2&camp=1789&creative=390957&creativ
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fsp = require("fs").promises; | |
const path = require("path"); | |
const { execSync } = require("child_process"); | |
const chalk = require("chalk"); | |
const Confirm = require("prompt-confirm"); | |
const jsonfile = require("jsonfile"); | |
const semver = require("semver"); | |
const packagesDir = path.resolve(__dirname, "../packages"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { promises } from "fs"; | |
import crypto from "crypto"; | |
import path from "path"; | |
import { print, parse } from "graphql"; | |
const plugin = { | |
name: "relay", | |
setup: build => { | |
build.onLoad({ filter: /\.tsx$/, namespace: "" }, async args => { | |
let contents = await promises.readFile(args.path, "utf8"); |
While this gist has been shared and followed for years, I regret not giving more background. It was originally a gist for the engineering org I was in, not a "general suggestion" for any React app.
Typically I avoid folders altogether. Heck, I even avoid new files. If I can build an app with one 2000 line file I will. New files and folders are a pain.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
your obj pointer came in the first position of the stack | |
so you will load it on a register | |
*/ | |
movl (%esp), %eax ; | |
/* | |
then you want to do obj.a += 6, if we suppose | |
that we're talking about records not dictionaries |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let level = 1 | |
const execute = (callback) => { | |
level++; | |
callback() | |
level--; | |
} | |
const print = text => { | |
console.log(' '.repeat(level) + text) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { useContext, useState } from 'react'; | |
import { ApolloContext } from 'react-apollo'; | |
import useDeepCompareEffect from 'use-deep-compare-effect'; | |
const useQuery = (query, { variables }) => { | |
const { client } = useContext(ApolloContext); | |
const [state, setState] = useState({ | |
loading: true, | |
}); |
sudo apt-get install net-tools
sudo apt-get install openssh-server
ssh-copy-id