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
// iPhone OS programming circa 2008 | |
// ================================ | |
NSInteger fruitSorter(NSString *a, NSString *b, void *context) { | |
return [a compare:b]; | |
} | |
// ... | |
NSMutableArray *fruits = [[NSMutableArray alloc] initWithObjects:@"apple", @"pear", @"banana", nil]; |
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
λ elixir -v | |
Elixir 0.13.3 | |
λ mix deps.get | |
* Getting jazz (git://github.com/meh/jazz.git) | |
Cloning into '/Users/alco/Documents/git/phoenix/webexample/deps/jazz'... | |
[...] | |
* Getting cowboy (git://github.com/extend/cowboy.git) | |
Cloning into '/Users/alco/Documents/git/phoenix/webexample/deps/cowboy'... | |
[...] |
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
λ kiex use 0.13.1 | |
Using 0.13.1 | |
λ mix compile | |
[...] | |
λ mix help muweb | |
# mix help muweb | |
Synopsis: |
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
[goxc:xc] 2014/06/13 01:53:08 invoking '/usr/local/Cellar/go/1.2.2/libexec/bin/go build -ldflags " -X main.BUILD_DATE '2014-06-13T01:53:08+03:00' -X main.VERSION 'snapshot' " -o /Users/alco/home/goworkspace/bin/goon-xc/snapshot/plan9_386/goon .' from '/Users/alco/extra/goworkspace/src/goon' | |
# goon | |
/Users/alco/home/goworkspace/src/goon/main.go:237: undefined: syscall.WaitStatus | |
/Users/alco/home/goworkspace/src/goon/main.go:238: s.ExitStatus undefined (type interface {} has no field or method ExitStatus) | |
[goxc:xc] 2014/06/13 01:53:08 'go' returned error: exit status 2 | |
[goxc:xc] 2014/06/13 01:53:08 Error: exit status 2 | |
[goxc:xc] 2014/06/13 01:53:08 Have you run `goxc -t` for this platform (386,plan9)??? |
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
. | |
├── muweb | |
│ ├── bin | |
│ │ ├── conform | |
│ │ ├── install_upgrade.escript | |
│ │ ├── muweb | |
│ │ ├── nodetool | |
│ │ └── start_clean.boot | |
│ ├── erl_crash.dump | |
│ ├── erts-6.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
mix) | |
# Make sure the config is generated first | |
generate_config | |
# start up the release in the foreground for use by runit | |
# or other supervision services | |
[ -f "$REL_DIR/$REL_NAME.boot" ] && BOOTFILE="$REL_NAME" || BOOTFILE="start" | |
FOREGROUNDOPTIONS="-noshell -noinput +Bd" | |
# Setup beam-required vars |
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
λ bin/muweb rpc file native_name_encoding | |
utf8 | |
λ bin/muweb rpc io setopts "[standard_io, [binary,{encoding,utf8}]]." | |
{error,enotsup} | |
λ bin/muweb rpc io setopts '[standard_error, [{unicode,true}]].' | |
{error,enotsup} |
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
λ rm -rf _build | |
~/Documents/git/phoenix/ master | |
λ l | |
total 384 | |
drwxr-xr-x 14 alco staff 476 Jun 10 14:59 .git | |
-rw-r--r-- 1 alco staff 77 Jun 10 14:57 .gitignore | |
-rw-r--r-- 1 alco staff 296 Jun 10 14:57 .travis.yml | |
-rw-r--r-- 1 alco staff 1056 May 1 14:11 LICENSE | |
-rw-r--r-- 1 alco staff 5552 Jun 10 14:57 README.md | |
drwxr-xr-x 10 alco staff 340 Jun 10 14:59 deps |
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
defmodule A do | |
defmodule B do | |
defstruct [:a, :b] | |
end | |
end | |
defmodule M do | |
import A | |
def hi() do |
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
iex(3)> defmodule D do | |
...(3)> defpool ping(pid, arg1, arg2) when is_pid(pid), do: IO.inspect pid | |
...(3)> end | |
[name: :ping] | |
[args: [{:pid, [line: 4], nil}, {:arg1, [line: 4], nil}, | |
{:arg2, [line: 4], nil}]] | |
[other_args: [{:arg1, [line: 4], nil}, {:arg2, [line: 4], nil}]] | |
[guards: [{:is_pid, [line: 4], [{:pid, [line: 4], nil}]}]] | |
[block: {{:., [line: 4], | |
[{:__aliases__, [counter: 0, line: 4], [:IO]}, :inspect]}, [line: 4], |