Skip to content

Instantly share code, notes, and snippets.

@meisinger
meisinger / setup-android-react-native.md
Last active February 19, 2020 02:21
Fun with Android, React-Native and Arch Linux

Install the android sdk, platform tools and build tools

yaourt -S android-sdk android-sdk-platform-tools android-sdk-build-tools

Android SDK

Was asked which JDK should be installed: opted for the default (jdk-openjdk)

@meisinger
meisinger / hex_commands.py
Last active February 12, 2020 21:45
Given a file, generates the HEX equivalent byte array
def parse_commands(commands):
hex_commands = []
for command in commands:
item = command.strip()
hex_value = ' '.join([str(hex(ord(i)))[2:4] for i in item])
hex_commands.append(item + ' = ' + '"' + hex_value + '"')
return hex_commands
def read_commands():
with open('commands.txt', 'r') as file:
version: '3'
services:
redis:
image: 'redis'
ports:
- '6379'
core:
build: ./core-api
extra_hosts:
- 'core.meisinger.com:196.168.1.10'
set -g default-terminal xterm-256color
set -g history-limit 10000
set-option -g prefix C-a
unbind C-b
bind-key C-a send-prefix
bind r source-file ~/.tmux.conf \; display "Reloaded!"
bind h select-pane -L
bind j select-pane -D
set encoding=utf-8
set termencoding=latin1
set nocompatible
call plug#begin('~/.vim/plugged')
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' }
Plug 'junegunn/fzf.vim'
Plug 'flazz/vim-colorschemes'
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
export TERM="xterm-256color"
export EDITOR='nvim'
export PATH=/usr/local/bin:$PATH
export PATH=/usr/local/sbin:$PATH
export ZSH="/Users/meisinger/.oh-my-zsh"
POWERLEVEL9K_MODE='nerdfont-complete'
ZSH_THEME="powerlevel9k/powerlevel9k"
plugins=(
@meisinger
meisinger / webpack.config.js
Created May 26, 2016 19:34
webpack basics
var path = require('path');
var webpack = require('webpack');
module.exports = {
devtool: 'eval',
entry: [
'./src/index'
],
output: {
path: path.join(__dirname, 'public'),
@meisinger
meisinger / main.js
Created January 7, 2016 23:27
example of react with a page view approach (no flux or events)
'use strict';
import React from 'react';
import ReactDom from 'react-dom';
import { UserService, ExampleService } from './service';
import Promise from 'bluebird';
import assign from 'object-assign';
class ComponentWrapper {
@meisinger
meisinger / example_bashrc.txt
Created December 17, 2015 05:39
arch linux stuff
#
# ~/.bashrc
#
export LANG=en_US.UTF-8
# If not running interactively, don't do anything
[[ $- != *i* ]] && return
alias ls='ls --color=auto -F'
alias grep='grep --color=auto'
@meisinger
meisinger / bootstrap.sh
Last active August 29, 2015 14:02
vagrant bootstrap
#!/usr/bin/env bash
## add redis to the package list
cat <<BAM >> /etc/apt/sources.list.d/dotdeb.org.list
# /etc/apt/sources.lsit.d/dotdeb.org.list
deb http://packages.dotdeb.org squeeze all
deb-src http://packages.dotdeb.org squeeze all
BAM
## import redis public key to package keys