Skip to content

Instantly share code, notes, and snippets.

@jastkand
jastkand / Dockerfile
Last active October 29, 2016 06:06
hackney handshake failure
FROM erlang:19.1
ENV APP_HOME /hackney
WORKDIR $APP_HOME
ADD . $APP_HOME
RUN rebar3 tree
CMD ["rebar3", "shell"]
@jastkand
jastkand / deploy.rb
Created June 26, 2017 06:31 — forked from noma4i/deploy.rb
Deploy Phoenix Elixir by mina
require 'mina/bundler'
require 'mina/git'
require 'mina/rbenv'
set :domain, 'your_domain.com'
set :deploy_to, '/home/deployer/app_name'
set :repository, '[email protected]:user_name/app_name'
set :branch, ENV["brunch"] || 'master'
set :app_name, "app_name"

Keybase proof

I hereby claim:

  • I am jastkand on github.
  • I am jastkand (https://keybase.io/jastkand) on keybase.
  • I have a public key ASBPn14FnSITRAlkzA9-Ul6_93w8YN-rWTKa9MlTzmBYzAo

To claim this, I am signing this object:

@jastkand
jastkand / hexToRGBA.js
Created December 11, 2018 14:47
hexToRGBA
// https://stackoverflow.com/questions/15898740/how-to-convert-rgba-to-a-transparency-adjusted-hex
function hexify(color) {
var values = color
.replace(/rgba?\(/, '')
.replace(/\)/, '')
.replace(/[\s+]/g, '')
.split(',');
var a = parseFloat(values[3] || 1),
r = Math.floor(a * parseInt(values[0]) + (1 - a) * 255),