Skip to content

Instantly share code, notes, and snippets.

@arielcr
arielcr / alacritty.toml
Created January 30, 2024 21:57
Alacritty Conf
import = [
"~/.config/alacritty/themes/themes/tomorrow_night.toml"
]
[font]
size = 14.0
[font.normal]
family = "JetBrainsMono Nerd Font"
style = "Regular"
@arielcr
arielcr / .tmux.conf
Last active January 30, 2024 23:00
MY TMUX.CONF
##set -sa terminal-overrides "*:Tc"
## remap prefix from 'C-b' to 'C-a'
unbind C-b
set-option -g prefix C-a
bind-key C-a send-prefix
## split panes using | and -
bind | split-window -h
bind - split-window -v
@arielcr
arielcr / .vimrc
Last active April 14, 2022 00:23
MY VIMRC
" =========================== PLUGINS ============================
" Install vim-plug for vim and neovim
if empty(glob('~/.vim/autoload/plug.vim'))
silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
endif
" Plugins
call plug#begin('~/.vim/plugged')
@arielcr
arielcr / times.csv
Created March 26, 2020 17:09
All the solvetimes as recorded in CLI Cube Timer, https://npmjs.org/package/cli-cube-timer
188.76 R' F' U R2 U L' D2 R' F2 R U F' U' L2 D B2 R2 F2 R' F2 1585242370136
@arielcr
arielcr / gist:78be4e41d7a9eaf87cf2
Created January 27, 2016 23:09
rsync with server
rsync -av /local/path/ root@xx.xx.xx.xx:/remote/path/
@arielcr
arielcr / allow-origin.php
Created September 8, 2014 16:52
Laravel filter to allowOrigin
Route::filter('allowOrigin', function($route, $request, $response)
{
$response->header('access-control-allow-origin','*');
});
@arielcr
arielcr / populate_select_box.js
Created May 6, 2014 17:44
Populate select box from JSON
$.getJSON('select.php', {customerId: $(this).val()}, function(data){
var vehicle = $('#vehicle');
for (var x = 0; x < data.length; x++) {
vehicle.append(new Option(data[x].reg, data[x].id));
}
});
@arielcr
arielcr / 0_reuse_code.js
Created May 6, 2014 17:35
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@arielcr
arielcr / Vagrantfile
Last active April 11, 2016 23:05
Vagrant file for Ruby on Rails
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.ssh.shell = "bash -c 'BASH_ENV=/etc/profile exec bash'"
config.vm.provision "shell", path: "https://gist.githubusercontent.com/arielcr/8845938/raw/b95e82166b24728df0d91b31dab9a65eed6cd01f/ror-provisioning.sh"
@arielcr
arielcr / ror-provisioning.sh
Last active September 30, 2020 00:14
Ruby on Rails Provisioning Script
#!/bin/bash
echo Provisioning Ruby on Rails...
echo =================================
echo - Installing dependencies
sudo apt-get update -y -qq > /dev/null
sudo apt-get install curl -y -qq > /dev/null
echo - Installing mysql server
export DEBIAN_FRONTEND=noninteractive