This gist is a list of options and tricks to make the amazing neovim work on OSX, from a former long time vim user.
This file contains hidden or 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
defmodule MyApp.HTTPClient do | |
@moduledoc """ | |
This module should be used to make http requests | |
""" | |
require Logger | |
require OK | |
defp decode_json(body) do | |
case Jason.decode(body) do | |
{:ok, decoded} -> decoded |
This file contains hidden or 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
za Toggle folds | |
c-r Redo | |
u Undo | |
c-p Search file | |
c-n Toggle nerdtree | |
c-s Search text in folder | |
s-h Move window left | |
s-l Move window right | |
c-h Move to left buffer | |
c-l Move to right buffer |
This file contains hidden or 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
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; | |
SET time_zone = "+00:00"; | |
CREATE TABLE IF NOT EXISTS `geo_locations` ( | |
`id` int(11) NOT NULL AUTO_INCREMENT, | |
`name` varchar(100) NOT NULL, | |
`parent_id` int(11) DEFAULT NULL, | |
`external_id` varchar(10) DEFAULT NULL, | |
`location_type` varchar(20) NOT NULL, | |
`pin` varchar(10) DEFAULT NULL, |
This file contains hidden or 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
touch ~/.android/repositories.cfg | |
brew cask install homebrew/cask-versions/adoptopenjdk8 | |
brew cask install android-sdk | |
brew cask install intel-haxm | |
brew install qt | |
export ANDROID_SDK_ROOT="/usr/local/share/android-sdk" | |
export JAVA_HOME="/Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home" | |
sdkmanager "platform-tools" "platforms;android-27" "extras;intel;Hardware_Accelerated_Execution_Manager" "build-tools;27.0.0" "system-images;android-27;google_apis;x86" "emulator" | |
avdmanager create avd -n test -k "system-images;android-27;google_apis;x86" | |
/usr/local/share/android-sdk/emulator/emulator -avd test |
This file contains hidden or 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 csv = require('csv'); | |
const express = require('express'); | |
const bodyParser = require('body-parser'); | |
const app = express(); | |
app.use(bodyParser.json()); |
This file contains hidden or 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
// Copied from SO | |
/** | |
* @param {Promise} promise | |
*/ | |
function reflect(promise) { | |
return promise | |
.then(d => { | |
return { |