Obj <- _ -> Obj <- _ -> Nat <- _ -> Nat Nat <- _ -> Nat <- _ -> Lit <- _ -> Lit
^ ^ ^ ^ ^ ^ ^ ^
| | | | | | | |
_ _ _ _ _ _ _ _
| | | | | | | |
v v v v v v v v
Obj <- _ -> Obj <- _ -> Nat <- _ -> Nat Nat <- _ -> Nat <- _ -> Lit <- _ -> Lit
^ ^ ^ ^ ^ ^ ^ ^
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
├── LICENSE: 29 lines | |
├── README.md: 12 lines | |
├── Setup.hs: 2 lines | |
├── app | |
│ └── Main.hs: 5 lines | |
├── git-details.cabal: 82 lines | |
├── src | |
│ ├── Data | |
│ │ ├── Attoparsec | |
│ │ │ └── Text |
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
let configpath = '/Users/michaelklein/.cvimrc' | |
let homedirectory = '/Users/michaelklein' | |
set localconfig | |
let vimcommand = 'urxvt -e vim' | |
imap <C-o> editWithVim | |
set smoothscroll | |
" set noautofocus | |
set cncpcompletion |
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/sh | |
# To squash the last three commits: git squash 3 | |
# It will open an interactive editor so you can | |
# more easily combine the comments | |
source "$(git --exec-path)/git-sh-setup" | |
USAGE="COMMITS" | |
function _squash() { |
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
unless Rails.env.production? | |
require 'ftpd' | |
require 'tmpdir' | |
puts "****** loading tmp_ftp *********" | |
class TmpFtp | |
def initialize(temp_dir) | |
@temp_dir = temp_dir | |
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
#!/bin/bash | |
# Create a post-checkout hook to show stashed changes | |
cd .git/hooks&&("#!/bin/sh\nexec git stash list --pretty=oneline --abbrev-commit">post-checkout)&&chmod +x post-checkout |
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
class Mock | |
attr_accessor :mock_original_name, :mock_call_stack | |
def self.on(x) | |
x.instance_eval do | |
def method_missing(symbol, *args) | |
puts "mocking #{self}.${symbol}(#{args.inspect})" | |
@mock_call_stack ||= [] | |
@mock_call_stack << [symbol, args] |
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
These benchmarks take about 45 minutes to run and perform a total of ~350k conversion (on my machine). | |
Here is the only significant win by pandoc-ruby: | |
Calculating ------------------------------------- | |
from: latex, to: latex, file: bomb.tex, pandoc_rb | |
0.020 (± 0.0%) i/s - 1.000 in 49.770525s | |
from: latex, to: latex, file: bomb.tex, pandoc-ruby (read file) | |
21.586 (± 3.4%) i/s - 104.000 in 5.025571s |
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
Comparison: | |
from: markdown, to: Fixnum, file: test2.md, sum bytes : 525983.2 i/s | |
from: markdown, to: Fixnum, file: test.md, sum bytes : 127658.3 i/s - 4.12x (± 0.14) slower | |
from: org, to: Fixnum, file: format.org, sum bytes : 123568.3 i/s - 4.26x (± 0.14) slower | |
from: markdown, to: Fixnum, file: format.markdown, sum bytes : 104980.1 i/s - 5.01x (± 0.33) slower | |
from: rst, to: Fixnum, file: format.rst, sum bytes : 98854.8 i/s - 5.32x (± 0.32) slower | |
from: textile, to: Fixnum, file: format.textile, sum bytes : 97966.4 i/s - 5.36x (± 0.29) slower | |
from: latex, to: Fixnum, file: format.latex, sum bytes : 87885.2 i/s - 5.98x (± 0.32) slower | |
from: latex, to: Fixnum, file: bomb.tex, sum bytes : 32267.8 i/s - 16.28x (± |
Bijection, from very explicit to very implicit:
Bijection := '(f := _) -> '(a := _) -> '(b := _) -> '(n := _ : Nat) -> '(m := _ : Nat) -> '(f : (a :# n) -> (b :# m)) -> '(n = m)
Bijection := '(f) -> '(a) -> '(b) -> '(n : Nat) -> '(m : Nat) -> '(f : (a :# n) -> (b :# m)) -> '(n = m)
Bijection := '(f) -> '(a) -> '(b) -> '(n) -> '(m) -> '(f : (a :# n) -> (b :# m)) -> '(n = m)
Bijection := '(f : (a :# n) -> (b :# m)) -> '(n = m)
Bijection := '(_ : (a :# n) -> (b :# m)) -> '(n = m)
Bijection := '(_ : (_ :# n) -> (_ :# m)) -> '(n = m)
Bijection := '(_ : (_ :# n) -> (_ :# n)) -> '(n = n)
Bijection := '((_ :# n) -> (_ :# n)) -> '(n = n)
OlderNewer