Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Writing Command Line Applications in Elixir
Search
James Smith
July 25, 2014
Programming
7
1.5k
Writing Command Line Applications in Elixir
Using Elixir to solve small problems.
James Smith
July 25, 2014
Tweet
Share
Other Decks in Programming
See All in Programming
Performance for Conversion! 分散トレーシングでボトルネックを 特定せよ
inetand
0
140
はじめてのMaterial3 Expressive
ym223
2
290
Updates on MLS on Ruby (and maybe more)
sylph01
1
180
機能追加とリーダー業務の類似性
rinchoku
2
1.3k
Ruby Parser progress report 2025
yui_knk
1
440
Introducing ReActionView: A new ActionView-compatible ERB Engine @ Rails World 2025, Amsterdam
marcoroth
0
690
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
360
rage against annotate_predecessor
junk0612
0
170
プロポーザル駆動学習 / Proposal-Driven Learning
mackey0225
2
1.3k
Tool Catalog Agent for Bedrock AgentCore Gateway
licux
6
2.4k
実用的なGOCACHEPROG実装をするために / golang.tokyo #40
mazrean
1
270
FindyにおけるTakumi活用と脆弱性管理のこれから
rvirus0817
0
510
Featured
See All Featured
For a Future-Friendly Web
brad_frost
180
9.9k
Faster Mobile Websites
deanohume
309
31k
Designing for humans not robots
tammielis
253
25k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Making Projects Easy
brettharned
117
6.4k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
15k
Music & Morning Musume
bryan
46
6.8k
How to Think Like a Performance Engineer
csswizardry
26
1.9k
Facilitating Awesome Meetings
lara
55
6.5k
4 Signs Your Business is Dying
shpigford
184
22k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.1k
The Art of Programming - Codeland 2020
erikaheidi
56
13k
Transcript
HELLO SEND(AUDIENCE, {:GREETING, “HELLO!”})
None
None
–interested programmer “I'd love to check out Elixir but I
don't really have a problem that is big enough that Elixir is well suited for.”
None
MASSIVELY CONCURRENT DISTRIBUTED FAULT TOLERANT WEB SCALE FUNCTIONAL
PIPES |> PATTERN MATCHING |> MESSAGE PASSING |> IMMUTABILITY |>
=> {:OK, “ ☺”} ELIXIR OFFERS A DIFFERENT WAY TO THINK ABOUT AND SOLVE PROBLEMS OF ANY SIZE. !
None
WRITING COMMANDLINE APPS WITH ELIXIR
None
None
MIX
DEPENDENCIES Hex package Git/SCM Path Dependency tasks mix deps: “lists
all deps and their status” mix deps.get “Get non installed dependencies” mix deps.compile mix deps.update mix deps.clean “Remove all dependency files” mix deps.unlock “Unlock dependencies”
None
UMBRELLA PROJECTS • Run tasks across apps • Run all
your tests for apps in app_path • Run Applications in dependent order…
MIX TASKS
RUNNING OUR APPS MIX ESCRIPT.BUILD
None
None
None
BASIC IO
TESTING IO
IO.ANSI • escape_fragment(string, emit \\ terminal()) • “%{clear, home, green,
bright} Welcome” • IO.red() IO.green() etc… • home() send the cursor home
FILES AND PATHS • File.open • File.close • File.read •
binread/write utf8 and IO module • File.read vs File.read! • Path.join and Path.expand • Path.wildcard
PORT
BASIC USAGE
DEMO
SCALING UP COMMAND LINE APPS WITH TASKS & AGENTS
TASKS
AGENTS a simple abstraction around state
DEMO DEMO
THANK YOU