]> njoseph.me Git - nimcoon.git/commitdiff
Be a nimble package
authorJoseph Nuthalapati <njoseph@riseup.net>
Thu, 20 Feb 2020 13:26:20 +0000 (18:56 +0530)
committerJoseph Nuthalapati <njoseph@riseup.net>
Thu, 20 Feb 2020 13:26:20 +0000 (18:56 +0530)
.gitlab-ci.yml
nimcoon.nimble [new file with mode: 0644]
src/config.nim [moved from config.nim with 100% similarity]
src/lib.nim [moved from lib.nim with 100% similarity]
src/nim.cfg [new file with mode: 0644]
src/nimcoon.nim [moved from nimcoon.nim with 100% similarity]
tests/nim.cfg [new file with mode: 0644]
tests/tests.nim [moved from tests.nim with 100% similarity]

index 9c9899f4ee769a3a53c20b4dbb0283a95f7631ce..f7727daf6c95ad46e233ea27fec118246b15c01a 100644 (file)
@@ -7,12 +7,12 @@ stages:
 run-unit-tests:
   stage: test
   script:
-    - nim c -d:ssl -r tests
+    - nimble test
 
 publish-artifacts:
   stage: publish
   script:
-    - nim c -d:ssl -d:release -d:quick --passc:-flto nimcoon.nim && strip nimcoon
+    - nimble build && strip nimcoon
   artifacts:
     paths:
       - nimcoon
diff --git a/nimcoon.nimble b/nimcoon.nimble
new file mode 100644 (file)
index 0000000..7b100c7
--- /dev/null
@@ -0,0 +1,12 @@
+# Package
+
+version       = "0.1.0"
+author        = "Joseph Nuthalapati"
+description   = "A command-line YouTube player and more"
+license       = "GPL-3.0"
+srcDir        = "src"
+bin           = @["nimcoon"]
+
+# Dependencies
+
+requires "nim >= 1.0.2"
similarity index 100%
rename from config.nim
rename to src/config.nim
similarity index 100%
rename from lib.nim
rename to src/lib.nim
diff --git a/src/nim.cfg b/src/nim.cfg
new file mode 100644 (file)
index 0000000..0580cd4
--- /dev/null
@@ -0,0 +1,3 @@
+-d:ssl
+-d:release
+-d:quick
similarity index 100%
rename from nimcoon.nim
rename to src/nimcoon.nim
diff --git a/tests/nim.cfg b/tests/nim.cfg
new file mode 100644 (file)
index 0000000..48ae85a
--- /dev/null
@@ -0,0 +1,2 @@
+--path:"../src/"
+-d:ssl
similarity index 100%
rename from tests.nim
rename to tests/tests.nim