Skip to content

Instantly share code, notes, and snippets.

Avatar
❄️
In the snow.

Johnny johnnymatthews

❄️
In the snow.
View GitHub Profile
View create-lotus-node.sh
sudo apt install mesa-opencl-icd ocl-icd-opencl-dev gcc git bzr jq pkg-config curl clang build-essential hwloc libhwloc-dev -y &&
sudo apt upgrade -y &&
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh &&
wget -c https://golang.org/dl/go1.15.5.linux-amd64.tar.gz -O - | sudo tar -xz -C /usr/local &&
echo "export PATH=$PATH:/usr/local/go/bin" >> ~/.bashrc &&
source ~/.bashrc &&
cd ~ && git clone https://github.com/filecoin-project/lotus.git &&
cd lotus && make clean all && sudo make install
View gist:eb2907014498b9daefdb96f1ada9e1f1
### Keybase proof
I hereby claim:
* I am johnnymatthews on github.
* I am johnnymatthews (https://keybase.io/johnnymatthews) on keybase.
* I have a public key ASDH3sVcXMOfVEtSgXZLcO1b95IQVvX0FZHkRohKooeloQo
To claim this, I am signing this object:
View semantic-commit-messages-for-documentations.md

Semantic pull request titles for documentation

Using these rules when creating a pull request title won't make you a better person, but it might improve your projects repository.

Types

These are the available types:

Type Description Example
@johnnymatthews
johnnymatthews / windows-terminal-settings.js
Last active Nov 10, 2020
My settings.json file for Windows Terminal. Remove the Azure and PowerShell 5.0 items.
View windows-terminal-settings.js
// This file was initially generated by Windows Terminal Preview 1.4.2652.0
// It should still be usable in newer versions, but newer versions might have additional
// settings, help text, or changes that you will not see unless you clear this file
// and let us generate a new one for you.
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
View verify-file-checksum.bash
# VERIFY A FILE'S CHECKSUM
# Enter the hash of the file from the website, and the name of
# the file, with an asterix * pre-pending it.
# shasum -a 256 -c <<<'HASH_OF_FILE_FROM_WEBSITE' '*NAME_OF_FILE'
# Here's an example:
shasum -a 256 -c <<<'302d795f6777ad187f978e9ca5eb11ae96930effd8816fa6380c7e14fdca98e9' '*coinomi-wallet-1.1.1-macos.dmg'
View keybindings.json
[
{
"key": "shift+cmd+g",
"command": "workbench.view.scm"
},
{
"key": "cmd+1",
"command": "workbench.action.openEditorAtIndex1"
},
{
View git-submodules.sh
# Add a submodule
git submodule add -b master https://github.com/mohnjatthews/docs content
git submodule init
# Update a submodule
git submodule update --remote
# Update a submodule that came with a cloned repo
git submodule update --init --remote
@johnnymatthews
johnnymatthews / cmus-osx.sh
Created Oct 10, 2019
Update your CMUS cache with a keypress.
View cmus-osx.sh
# 1. Create a file called update-library.sh and add the following lines.
#!/bin/bash
cmus-remote -C clear
cmus-remote -C "add ~/Music"
cmus-remote -C "update-cache -f"
cp ~/Music/Playlists/* ~/.config/cmus/
# 2. Change permissions to make the script executable:
@johnnymatthews
johnnymatthews / Recover Public from Private SSH Key
Last active Jan 17, 2019
This line allows you to recover your public ssh key from your private key. Assuming your private key is called `id_rsa` and you want your public key to be called `id_rsa.pub`.
View Recover Public from Private SSH Key
# This line allows you to recover your public ssh key from your private key.
# Assuming your private key is called `id_rsa` and you want your public key
# to be called `id_rsa.pub`.
ssh-keygen -y -f ~/.ssh/id_rsa > ~/.ssh/id_rsa.pub
# Your id_rsa file needs to have the correct permissions assigned to it. Run
# this line to set them.
sudo chmod 600 ~/.ssh.id_rsa
View VSCode Settings.json
{
"editor.fontSize": 14,
"editor.lineHeight": 30,
"editor.minimap.enabled": true,
"editor.minimap.showSlider": "always",
"editor.wordWrap": "on",
"editor.detectIndentation": false,
"explorer.confirmDelete": false,
"terminal.integrated.fontSize": 14,
"window.zoomLevel": 0,