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
# SEE THE GEM https://github.com/terry90/user_notif | |
# config/application.rb | |
config.autoload_paths += %W(#{config.root}/app/models/notifications) |
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
# frozen_string_literal: true | |
require 'yaml' | |
require 'erb' | |
require 'active_record' | |
config_dir = File.expand_path('../', __FILE__) | |
config_content = File.read(File.join(config_dir, 'database.yml')) | |
db_conf = YAML.safe_load(ERB.new(config_content).result) |
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 this to init.coffee in ~/.atom/ | |
{BufferedProcess} = require 'atom' | |
rubocopOutput = (data) -> | |
if (data.stderr) | |
atom.notifications.addError(data.stderr) | |
return | |
if (data.summary.offense_count == 0) | |
atom.notifications.addSuccess('No offenses found') | |
for file in data.files |
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
[ | |
{ | |
"id": "Angular.ng-template", | |
"name": "ng-template", | |
"publisher": "Angular", | |
"version": "0.1.9" | |
}, | |
{ | |
"id": "CoenraadS.bracket-pair-colorizer", | |
"name": "bracket-pair-colorizer", |
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
FROM rustlang/rust:nightly-slim as build | |
# Dependencies cache | |
WORKDIR /app/ | |
COPY Cargo.toml . | |
COPY Cargo.lock . | |
RUN mkdir src | |
RUN echo "fn main() {}" > src/main.rs |
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
FROM clux/muslrust as build | |
WORKDIR /app/ | |
# Deps caching begins | |
COPY Cargo.toml . | |
COPY Cargo.lock . | |
RUN mkdir src | |
RUN echo "fn main() {}" > src/main.rs |
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
const SPEED = 150 // ms | |
// Open the console and paste this on linkedin.com/feed/following | |
function unfollowCurrent(elems, callback) { | |
console.log('Unfollowing ', elems.length, ' contacts') | |
elems.forEach( | |
(e, i) => | |
setTimeout(() => e.click(), i * SPEED) | |
) | |
setTimeout(callback, elems.length * SPEED) |
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
export ZSH="$HOME/.oh-my-zsh" | |
ZSH_THEME="spaceship" | |
plugins=( | |
git | |
zsh-syntax-highlighting | |
zsh-autosuggestions | |
zsh-completions | |
) |
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
#!/usr/bin/zsh | |
chsh -s $(which zsh) | |
sudo pacman -Syu | |
sudo pacman -S bat --noconfirm | |
sudo pacman -S lsd --noconfirm | |
sudo pacaur -S nerd-fonts-source-code-pro --noconfirm --noedit | |
sudo pacman -S code --noconfirm | |
sudo pacman -S pacaur --noconfirm |
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
#!/usr/bin/zsh | |
gcloud auth login | |
gcloud auth configure-docker | |
gcloud config set compute/zone europe-west1-b | |
gcloud config set compute/region europe-west1 | |
echo "Cluster name?" | |
read "cluster?: " |
OlderNewer