Skip to content

Instantly share code, notes, and snippets.

@danikkks
danikkks / alfred_alacritty_tmux.applescript
Created April 28, 2025 16:51
Alfred + Alacritty + tmux integration
on ensureAlacritty()
tell application "System Events"
set wasRunning to (exists (process "Alacritty"))
end tell
tell application "Alacritty" to activate
-- Make absolutely sure the Alacritty process is front-most
tell application "System Events"
set frontmost of process "Alacritty" to true
git branch --merged | grep -v "master" | xargs git branch -D
@danikkks
danikkks / pushToImmutableArray.js
Created August 5, 2016 06:26
pushToImmutableArray
const myMap = Immutable.fromJS({
nested: {
someKey: ['hello', 'world'],
},
});
const myNewMap = myMap.updateIn(['nested', 'someKey'], arr => arr.push('bye'));
export default function camelCaseToDash(string) {
return string.replace(/([A-Z])/g, function($1){return "-"+$1.toLowerCase()});
}
var gulp = require('gulp');
var styl = require('gulp-stylus');
var jade = require('gulp-jade');
var babel = require('gulp-babel');
var livereload = require('gulp-livereload');
var sourcemaps = require('gulp-sourcemaps');
var autoprefixer = require('gulp-autoprefixer');
var input = {
'jade': './source/index.jade',
# This file has been auto-generated by i3-config-wizard(1).
# It will not be overwritten, so edit it as you like.
#
# Should you change your keyboard layout somewhen, delete
# this file and re-run i3-config-wizard(1).
#
# i3 config file (v4)
#
# Please see http://i3wm.org/docs/userguide.html for a complete reference!
javascript:void((function(){var a,b,c,d,e,f;f=new Array("pink","orange","yellow","aquamarine","lightskyblue","plum");for(a=1;a<=6;a++){b=document.getElementsByTagName("h"+a);for(c=0;c<b.length;c++){d=b[c];e=d.style;e.backgroundColor=f[a-1];e.border="1px solid black";e.color="black";d.innerHTML="H"+a+" "+d.innerHTML;}}})())
" Note: Skip initialization for vim-tiny or vim-small.
if 0 | endif
if &compatible
set nocompatible " Be iMproved
endif
" Required:
set runtimepath^=~/.vim/bundle/neobundle.vim/