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
# Define a function that switches iterm profile | |
iterm2_profile() { echo -e "\033]50;SetProfile=$1\a"; } | |
# Change profile by $HOUR | |
# You'll need to change name of profiles to Light and Dark | |
HOUR=`date +"%H"` | |
if [ $HOUR -gt 6 ] && [ $HOUR -lt 18 ]; | |
then iterm2_profile Light; | |
else iterm2_profile Dark; | |
fi |
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
#!/bin/bash | |
kwmc=$HOME/bin/kwmc | |
currentFocus=$($kwmc query focus-follows-mouse) | |
currentMouse=$($kwmc query mouse-follows-focus) | |
tag=$($kwmc query space active mode) | |
if [ "$1" = 'quit' ]; then | |
killall kwm |
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
//app/Models/Page.php | |
<?php | |
namespace App\Models; | |
use A17\Twill\Models\Behaviors\HasBlocks; | |
use A17\Twill\Models\Behaviors\HasSlug; | |
use A17\Twill\Models\Behaviors\HasMedias; | |
use A17\Twill\Models\Behaviors\HasRevisions; |
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
$ cd /System/Library/QuickLook | |
$ sudo wget http://trinity.neooffice.org/downloads/neopeek.qlgenerator.tgz | tar xzvf |
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
<html> | |
<body> | |
<a href="karabiner://karabiner/assets/complex_modifications/import?url=https%3A%2F%2Fgist.githubusercontent.com%2Fslowkow%2F275e53573e2aeb60c8304add1e54faf5%2Fraw%2Fc63540925dba76f46293834c24700ebf1578ed10%2Fmouse-buttons-back-forward.json">click here to import into Karabiner-Elements</a> | |
</body> | |
</html> |
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
hs.hotkey.bind({"cmd", "alt", "ctrl"}, "W", function() | |
hs.alert.show( | |
"Hello World!", | |
{ | |
textFont= "Comic Sans MS", | |
textSize=72, | |
fadeOutDuration=1 | |
} | |
) | |
end) |
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
" deoplete.vim contains vim settings relevant to the deoplete autocompletion | |
" plugin | |
" for more details about my neovim setup see: | |
" http://afnan.io/2018-04-12/my-neovim-development-setup/ | |
" deoplete options | |
let g:deoplete#enable_at_startup = 1 | |
let g:deoplete#enable_smart_case = 1 | |
" disable autocomplete by default |
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
hs.window.animationDuration = 0 -- disable animations | |
local menuHeight = 40 | |
local W = hs.window | |
local WF = hs.window.filter | |
local G = hs.geometry | |
function getWindowsBehind(region) | |
local wf = WF.copy(WF.defaultCurrentSpace):setRegions({region}) |
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
--[[ | |
-- To get the icons working correctly: | |
-- 1. Install nonicons.ttf from https://github.com/yamatsum/nonicons | |
-- 2. Install nvim plugin https://github.com/yamatsum/nvim-nonicons | |
--]] | |
local gl = require("galaxyline") | |
local gls = gl.section | |
local fileinfo = require('galaxyline.provider_fileinfo') | |
local iconz = require("nvim-nonicons") |
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
-- Usage: type :IncrementalRename <new_name> while your cursor is placed above an identifier (LSP must be enabled) | |
-- Update: this gist will no longer be updated since this command has been turned into a plugin! | |
-- You can find the plugin here: https://github.com/smjonas/inc-rename.nvim | |
local state = { | |
added_lines = false, | |
orig_lines = {}, | |
lsp_positions = {}, | |
} |
OlderNewer