diff --git a/firefly/main.py b/firefly/main.py
index bb06d97..37eb583 100644
--- a/firefly/main.py
+++ b/firefly/main.py
@@ -7,7 +7,7 @@ from .server import FireflyServer
 def parse_args():
     p = argparse.ArgumentParser()
     p.add_argument("-b", "--bind", dest="ADDRESS", default="127.0.0.1:8000")
-    p.add_argument("function", help="function to serve")
+    p.add_argument("functions", nargs='+', help="functions to serve")
     return p.parse_args()
 
 def load_function(function_spec):
@@ -17,7 +17,14 @@ def load_function(function_spec):
     mod_name, func_name = function_spec.rsplit(".", 1)
     mod = importlib.import_module(mod_name)
     func = getattr(mod, func_name)
-    return func
+    return (func_name, func)
+
+def load_functions(function_specs):
+    return [load_function(function_spec) for function_spec in function_specs]
+
+def add_routes(app, functions):
+    for name, function in functions:
+        app.add_route('/'+name, function)
 
 def main():
     # ensure current directory is added to sys.path
@@ -25,10 +32,10 @@ def main():
         sys.path.insert(0, "")
 
     args = parse_args()
-    function = load_function(args.function)
+    functions = load_functions(args.functions)
 
     app = Firefly()
-    app.add_route("/", function)
+    add_routes(app, functions)
 
     server = FireflyServer(app, {"bind": args.ADDRESS})
     server.run()

Allow firefly to support multiple functions
It should take multiple functions as command line arguments and expose all of them.

```
$ firefly myfile.square myfile.cube
```
And use:

```
$ curl -d '{"x": 5}' http://localhost:8000/square
25
$ curl -d '{"x": 5}' http://localhost:8000/cube
125
```
diff --git a/tests/test_main.py b/tests/test_main.py
new file mode 100644
index 0000000..7ecfbf2
--- /dev/null
+++ b/tests/test_main.py
@@ -0,0 +1,8 @@
+import os
+from firefly.main import load_function
+
+def test_load_functions():
+    os.path.exists2 = os.path.exists
+    name, func = load_function("os.path.exists2")
+    assert name == "exists2"
+    assert func == os.path.exists

pip install -e .
parse_log_pytest
requirements.txt
pytest
apt-get update apt-get install -y gcc
3.6
requirements.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
attrs==22.2.0
certifi==2021.5.30
-e git+https://github.com/rorodata/firefly.git@8f85f769b450eb45d9b4e3a338e988a042bf7459#egg=Firefly
gunicorn==19.7.1
importlib-metadata==4.8.3
iniconfig==1.1.1
packaging==21.3
pluggy==1.0.0
py==1.11.0
pyparsing==3.1.4
pytest==7.0.1
tomli==1.2.3
typing_extensions==4.1.1
WebOb==1.7.2
zipp==3.6.0

name: firefly
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2021.5.30=py36h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.3=he6710b0_2
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=21.2.2=py36h06a4308_0
  - python=3.6.13=h12debd9_1
  - readline=8.2=h5eee18b_0
  - setuptools=58.0.4=py36h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.37.1=pyhd3eb1b0_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - attrs==22.2.0
      - gunicorn==19.7.1
      - importlib-metadata==4.8.3
      - iniconfig==1.1.1
      - packaging==21.3
      - pluggy==1.0.0
      - py==1.11.0
      - pyparsing==3.1.4
      - pytest==7.0.1
      - tomli==1.2.3
      - typing-extensions==4.1.1
      - webob==1.7.2
      - zipp==3.6.0
prefix: /opt/conda/envs/firefly

tests/test_main.py::test_load_functions
firefly/main.py
firefly/main.py