Skip to content

Commit

Permalink
update hammerspoon and atom config
Browse files Browse the repository at this point in the history
  • Loading branch information
bluemaex committed Jul 18, 2018
1 parent 8bc192a commit 53522db
Show file tree
Hide file tree
Showing 6 changed files with 60 additions and 2 deletions.
53 changes: 53 additions & 0 deletions osx/etc-sym/.hammerspoon/caffeine.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
-- Hammerspoon replacement for Caffeine
-- https://gist.github.com/heptal/50998f66de5aba955c00

local ampOnIcon = [[ASCII:
.....1a..........AC..........E
..............................
......4.......................
1..........aA..........CE.....
e.2......4.3...........h......
..............................
..............................
.......................h......
e.2......6.3..........t..q....
5..........c..........s.......
......6..................q....
......................s..t....
.....5c.......................
]]

local ampOffIcon = [[ASCII:
.....1a.....x....AC.y.......zE
..............................
......4.......................
1..........aA..........CE.....
e.2......4.3...........h......
..............................
..............................
.......................h......
e.2......6.3..........t..q....
5..........c..........s.......
......6..................q....
......................s..t....
...x.5c....y.......z..........
]]

local caffeine = hs.menubar.new()

function setCaffeineDisplay(state)
if state then
caffeine:setIcon(ampOnIcon)
else
caffeine:setIcon(ampOffIcon)
end
end

function caffeineClicked()
setCaffeineDisplay(hs.caffeinate.toggle("displayIdle"))
end

if caffeine then
caffeine:setClickCallback(caffeineClicked)
setCaffeineDisplay(hs.caffeinate.get("displayIdle"))
end
1 change: 1 addition & 0 deletions osx/etc-sym/.hammerspoon/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ require "window-layout"
require "wallpaper"
require "wifi"
require "usb"
require "caffeine"

-- print config loaded
hs.notify.show("Loaded Config", "Have fun!", "")
2 changes: 1 addition & 1 deletion osx/etc-sym/.hammerspoon/window-grid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ local gh = hs.grid.GRIDHEIGHT
hs.hotkey.bind(hyper, 'Left', gridset({x = 0, y = 0, w = gw/2, h = gh}))
hs.hotkey.bind(hyper, 'Right', gridset({x = gw/2, y = 0, w = gw/2, h = gh}))
hs.hotkey.bind(hyper, 'Up', gridset({x = 0, y = 0, w = gw, h = gh/2}))
hs.hotkey.bind(hyper, 'Down', gridset({x = 0, y = 0, w = gw, h = gh/2}))
hs.hotkey.bind(hyper, 'Down', gridset({x = 0, y = gh/2, w = gw, h = gh/2}))

-- move window position inside the grid
hs.hotkey.bind(hyper_shift, 'Left', hs.grid.pushWindowLeft)
Expand Down
1 change: 0 additions & 1 deletion osx/etc-sym/.lolcommits

This file was deleted.

5 changes: 5 additions & 0 deletions osx/etc/.atom/config.cson
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
screenShake: true
screenShake:
enabled: false
"atom-ide-ui":
use: {}
core:
disabledPackages: [
"language-javascript"
Expand All @@ -26,6 +28,8 @@
panelHeight: 69
showPanel: true
minimap: {}
"php-ide-serenata":
storagePath: "/Users/bluemaex/Library/Preferences/php-ide-serenata"
"php-integrator-base":
general:
indexContinuously: false
Expand All @@ -39,6 +43,7 @@
defaultShowInherited: true
"prettier-atom":
formatOnSaveOptions:
enabled: true
isDisabledIfNotInPackageJson: true
showInStatusBar: true
prettierOptions:
Expand Down
File renamed without changes.

0 comments on commit 53522db

Please sign in to comment.