This file contains hidden or 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
| " Remove trailing whitespace | |
| command! StripTrailingWhitespaces call <SID>StripTrailingWhitespaces() | |
| nmap ,ws :StripTrailingWhitespaces<CR> | |
| " Strip whitespace | |
| function! <SID>StripTrailingWhitespaces() | |
| " Preparation: save last search, and cursor position. | |
| let _s=@/ | |
| let l = line(".") | |
| let c = col(".") |
This file contains hidden or 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
| function window.init_funcs.auto_session_save (w) | |
| w.tabs:add_signal("page-removed", function () | |
| if not session.closing then | |
| w:save_session() | |
| end | |
| end) | |
| session.closing = false | |
| session.old_close_win = w.close_win | |
| w.close_win = function (w, force) | |
| session.closing = true |
This file contains hidden or 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
| set_jquery_speed = function (view, w) | |
| view:add_signal("load-status", function (v, status) | |
| if status == "finished" and v.uri ~= "luakit://" then | |
| v:eval_js([=[ | |
| if ($) { | |
| $.fx.speeds._default = 70; | |
| } | |
| ]=]) | |
| end | |
| end) |
This file contains hidden or 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
| " Vim syntax file | |
| " | |
| " Modification of vims Haskell syntax file: | |
| " - match types using regular expression | |
| " - highlight toplevel functions | |
| " - use "syntax keyword" instead of "syntax match" where appropriate | |
| " - functions and types in import and module declarations are matched | |
| " - removed hs_highlight_more_types (just not needed anymore) | |
| " - enable spell checking in comments and strings only | |
| " - FFI highlighting |
This file contains hidden or 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/env perl | |
| use 5.013; | |
| use warnings; | |
| use Data::Dumper; | |
| use File::Basename; | |
| use File::Spec::Functions; | |
| use File::Path qw(make_path); | |
| my $pdftk = `/usr/bin/which pdftk`; |
This file contains hidden or 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/env escript | |
| -define(DELAY, 1000). | |
| main(_Depth) -> | |
| S = self(), | |
| spawn(fun() -> keepGoing(50, S, 0) end), | |
| spawn(fun() -> keepGoing(50, S, 0) end), | |
| X = collectKids(), | |
| io:format("\p\n", [X]), |
This file contains hidden or 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
| -record(state, {server, | |
| name="", | |
| to_go=0}). |
This file contains hidden or 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
| loop(S = #state{server=Server, to_go=[T|Next]}) -> | |
| receive | |
| {Server, Ref, cancel} -> | |
| Server ! {Ref, ok} | |
| after T*1000 -> | |
| if Next =:= [] -> | |
| Server ! {done, S#state.name}; | |
| Next =/= [] -> | |
| loop(S#state{to_go=Next}) | |
| end |
This file contains hidden or 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
| -module(kitchen). | |
| -compile(export_all). %% Probably replace with -export([funcs]) | |
| -author("John Tyree"). | |
| fridge2(FoodList) -> | |
| receive | |
| {From, show} -> | |
| From ! {self(), FoodList}, | |
| fridge2(FoodList); | |
| {From, {store, Food}} -> |
This file contains hidden or 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
| print('what?!') |