From 0b9df128b75dd1744d383c6e452a041c4b6ec078 Mon Sep 17 00:00:00 2001 From: Andrea Date: Tue, 2 Sep 2025 08:24:54 +0200 Subject: [PATCH] init --- .gitignore | 3 +++ README.md | 11 +++++++++++ bin/.gitkeep | 0 nimproj.nimble | 15 +++++++++++++++ src/main.nim | 6 ++++++ tests/config.nims | 1 + tests/test_main.nim | 11 +++++++++++ 7 files changed, 47 insertions(+) create mode 100644 .gitignore create mode 100644 README.md create mode 100644 bin/.gitkeep create mode 100644 nimproj.nimble create mode 100644 src/main.nim create mode 100644 tests/config.nims create mode 100644 tests/test_main.nim diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..37a6a72 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ + +bin/* +!bin/.gitkeep \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..7e9dcd3 --- /dev/null +++ b/README.md @@ -0,0 +1,11 @@ +## Nimpro + +A little template for Nim projects. + +## Testing + +In order to test the project run: + +``` +nimble test +``` \ No newline at end of file diff --git a/bin/.gitkeep b/bin/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/nimproj.nimble b/nimproj.nimble new file mode 100644 index 0000000..783831b --- /dev/null +++ b/nimproj.nimble @@ -0,0 +1,15 @@ +# Package + +version = "0.1.0" +author = "" +description = "" +license = "MIT" +bin = @["main"] +srcDir = "src" +binDir = "bin" +installExt = @["nim"] + + +# Dependencies + +requires "nim >= 2.0.8" diff --git a/src/main.nim b/src/main.nim new file mode 100644 index 0000000..14cc1e3 --- /dev/null +++ b/src/main.nim @@ -0,0 +1,6 @@ + +proc main = + return + +when isMainModule: + main() diff --git a/tests/config.nims b/tests/config.nims new file mode 100644 index 0000000..3bb69f8 --- /dev/null +++ b/tests/config.nims @@ -0,0 +1 @@ +switch("path", "$projectDir/../src") \ No newline at end of file diff --git a/tests/test_main.nim b/tests/test_main.nim new file mode 100644 index 0000000..1b022a9 --- /dev/null +++ b/tests/test_main.nim @@ -0,0 +1,11 @@ +# This is just an example to get you started. You may wish to put all of your +# tests into a single file, or separate them into multiple `test1`, `test2` +# etc. files (better names are recommended, just make sure the name starts with +# the letter 't'). +# +# To run these tests, simply execute `nimble test`. + +import unittest + +test "assert the truth": + check true