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
# Add your machine IP as allowed for Python server as well as for CRA (Create React App). | |
# You than have to start the server with this IP like: | |
# python manage.py runserver 192.168.0.168:8000 | |
ALLOWED_HOSTS = [ | |
'192.168.0.168' | |
] | |
# CRA_HOST and CRA_PORT are from the 'cra_helper' app installed in the project as well. | |
# Tells the base.html where to load the scripts from. |
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
package main | |
import ( | |
"fmt" | |
) | |
func main() { | |
fmt.Printf("Hello, world.\n") | |
} |
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
random-string() | |
{ | |
cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w ${1:-32} | head -n 1 | |
} |
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
# If you come from bash you might have to change your $PATH. | |
# export PATH=$HOME/bin:/usr/local/bin:$PATH | |
# Path to your oh-my-zsh installation. | |
export ZSH=/home/vaso/.oh-my-zsh | |
# Set name of the theme to load. Optionally, if you set this to "random" | |
# it'll load a random theme each time that oh-my-zsh is loaded. | |
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes | |
ZSH_THEME="robbyrussell" |
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
# Change prefix from C-a from C-b | |
set -g prefix C-a | |
# Prefix has been remapped, C-b can be unbinded | |
unbind C-b | |
# Reduces the delay; more responsive command execution | |
set -s escape-time 1 | |
# Indexing from 1 instead of 0 | |
set -g base-index 1 | |
set -g pane-base-index 1 |
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
# source: https://www.leggiero.uk/post/installing-adobe-source-code-pro-fonts/ | |
wget https://github.com/adobe-fonts/source-code-pro/archive/2.010R-ro/1.030R-it.zip | |
unzip 1.030R-it.zip | |
mkdir -p ~/.fonts | |
mv source-code-pro-2.010R-ro-1.030R-it/OTF/*.otf ~/.fonts | |
rm -r 1.030R-it.zip source-code-pro-2.010R-ro-1.030R-it | |
fc-cache -f -v |
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
Windows Registry Editor Version 5.00 | |
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout] | |
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00 |
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
# Windows | |
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout | |
> new binary value named "Scancode Map" with value | |
> 00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00 | |
> restart PC | |
# Debian |
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
# Install tmux on Centos release 6.5 | |
# install deps | |
yum install gcc kernel-devel make ncurses-devel | |
# DOWNLOAD SOURCES FOR LIBEVENT AND MAKE AND INSTALL | |
curl -OL https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz | |
tar -xvzf libevent-2.0.21-stable.tar.gz | |
cd libevent-2.0.21-stable | |
./configure --prefix=/usr/local |
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
# Inspired by https://github.com/vinodpandey/blog/blob/master/vim7.3-centos-with-python-2.7.3-support.txt | |
# http://rm-rf.es/usrbinld-cannot-find-lpython2-6/ | |
# Install neccessary packages for both Python installation and Vim compilation | |
# ============================================================================= | |
sudo yum groupinstall 'Development Tools' | |
sudo yum install openssl-devel zlib ncurses ncurses-devel bzip-devel python-devel | |
# Missing python-devel will lead to /usr/bin/ld: cannot find -lpython2.6 | |
# Configure and install Vim |
NewerOlder