···11+-- Project-local nvim config for glox.
22+-- Auto-loaded when nvim starts here (requires `vim.opt.exrc = true`).
33+-- Run `:trust` once to allowlist this file.
44+55+local function gleam_run_float()
66+ Snacks.terminal({ "gleam", "run" }, {
77+ cwd = vim.fn.getcwd(),
88+ win = {
99+ style = "float",
1010+ border = "rounded",
1111+ width = 0.85,
1212+ height = 0.8,
1313+ },
1414+ interactive = true,
1515+ })
1616+end
1717+1818+vim.keymap.set("n", "<leader>gr", gleam_run_float, { silent = true, desc = "Gleam: run (float)" })
1919+2020+vim.api.nvim_create_user_command("GleamRun", gleam_run_float, {})
+20
Makefile
···11+.PHONY: build test test-expr run clean
22+33+build:
44+ gleam build
55+66+test:
77+ gleam test
88+99+test-expr: build
1010+ gleam build --target erlang
1111+ erl -pa build/dev/erlang/*/ebin -noshell \
1212+ -eval 'eunit:test(expr_test, [verbose]).' \
1313+ -s init stop
1414+1515+run:
1616+ @if [ -z "$(FILE)" ]; then gleam run; \
1717+ else gleam run -- "$(FILE)"; fi
1818+1919+clean:
2020+ rm -rf build
+24
README.md
···11+# glox
22+33+[](https://hex.pm/packages/glox)
44+[](https://hexdocs.pm/glox/)
55+66+```sh
77+gleam add glox@1
88+```
99+```gleam
1010+import glox
1111+1212+pub fn main() -> Nil {
1313+ // TODO: An example of the project in use
1414+}
1515+```
1616+1717+Further documentation can be found at <https://hexdocs.pm/glox>.
1818+1919+## Development
2020+2121+```sh
2222+gleam run # Run the project
2323+gleam test # Run the tests
2424+```
···11+name = "glox"
22+version = "1.0.0"
33+44+# Fill out these fields if you intend to generate HTML documentation or publish
55+# your project to the Hex package manager.
66+#
77+# description = ""
88+# licences = ["Apache-2.0"]
99+# repository = { type = "github", user = "", repo = "" }
1010+# links = [{ title = "Website", href = "" }]
1111+#
1212+# For a full reference of all the available options, you can have a look at
1313+# https://gleam.run/writing-gleam/gleam-toml/.
1414+1515+[dependencies]
1616+gleam_stdlib = ">= 0.44.0 and < 2.0.0"
1717+argv = ">= 1.0.2 and < 2.0.0"
1818+input = ">= 1.0.1 and < 2.0.0"
1919+simplifile = ">= 2.4.0 and < 3.0.0"
2020+2121+[dev_dependencies]
2222+gleeunit = ">= 1.0.0 and < 2.0.0"
+18
manifest.toml
···11+# This file was generated by Gleam
22+# You typically do not need to edit this file
33+44+packages = [
55+ { name = "argv", version = "1.0.2", build_tools = ["gleam"], requirements = [], otp_app = "argv", source = "hex", outer_checksum = "BA1FF0929525DEBA1CE67256E5ADF77A7CDDFE729E3E3F57A5BDCAA031DED09D" },
66+ { name = "filepath", version = "1.1.2", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "filepath", source = "hex", outer_checksum = "B06A9AF0BF10E51401D64B98E4B627F1D2E48C154967DA7AF4D0914780A6D40A" },
77+ { name = "gleam_stdlib", version = "1.0.0", build_tools = ["gleam"], requirements = [], otp_app = "gleam_stdlib", source = "hex", outer_checksum = "960090C2FB391784BB34267B099DC9315CC1B1F6013E7415BC763CEF1905D7D3" },
88+ { name = "gleeunit", version = "1.10.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "gleeunit", source = "hex", outer_checksum = "254B697FE72EEAD7BF82E941723918E421317813AC49923EE76A18C788C61E72" },
99+ { name = "input", version = "1.0.1", build_tools = ["gleam"], requirements = [], otp_app = "input", source = "hex", outer_checksum = "FE84CDADC78A1367E4AFD561A529825A8FEC88D165CBDF511FD3226CABCDEE6F" },
1010+ { name = "simplifile", version = "2.4.0", build_tools = ["gleam"], requirements = ["filepath", "gleam_stdlib"], otp_app = "simplifile", source = "hex", outer_checksum = "7C18AFA4FED0B4CE1FA5B0B4BAC1FA1744427054EA993565F6F3F82E5453170D" },
1111+]
1212+1313+[requirements]
1414+argv = { version = ">= 1.0.2 and < 2.0.0" }
1515+gleam_stdlib = { version = ">= 0.44.0 and < 2.0.0" }
1616+gleeunit = { version = ">= 1.0.0 and < 2.0.0" }
1717+input = { version = ">= 1.0.1 and < 2.0.0" }
1818+simplifile = { version = ">= 2.4.0 and < 3.0.0" }