Home

Awesome

argv

A cross platform library for getting the command line arguments.

Package Version Hex Docs

gleam add argv
import argv
import gleam/io

pub fn main() {
  case argv.load().arguments {
    ["hello", name] ->
      io.println("Hello, " <> name <> "!")
    _ ->
      io.println("usage: ./program hello <name>")
  }
}