mirror of
https://github.com/logos-messaging/waku-nimble-import.git
synced 2026-01-02 14:13:09 +00:00
Initial Commit
This commit is contained in:
commit
b114cacf2b
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
/nimbledeps
|
||||||
|
/nimble_test
|
||||||
11
README.md
Normal file
11
README.md
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# Waku Nimble Import
|
||||||
|
|
||||||
|
This project shows a basic import of waku along, with some other libraries which would be required in many applications.
|
||||||
|
|
||||||
|
|
||||||
|
# Building
|
||||||
|
|
||||||
|
`nimble -l install` : Uses localDeps to simulate a clean installation, and not impacted by state of the nimble environment.
|
||||||
|
|
||||||
|
`nimble run`
|
||||||
|
|
||||||
23
nimble_test.nimble
Normal file
23
nimble_test.nimble
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
# Package
|
||||||
|
|
||||||
|
version = "0.2.1"
|
||||||
|
author = "Jazz Turner-Baggs"
|
||||||
|
description = "A new awesome nimble package"
|
||||||
|
license = "MIT"
|
||||||
|
srcDir = "src"
|
||||||
|
installExt = @["nim"]
|
||||||
|
bin = @["nimble_test"]
|
||||||
|
|
||||||
|
|
||||||
|
# Dependencies
|
||||||
|
|
||||||
|
requires "nim >= 2.2.4",
|
||||||
|
"waku == 0.36.0",
|
||||||
|
"protobuf_serialization",
|
||||||
|
"blake2",
|
||||||
|
"constantine",
|
||||||
|
"libp2p",
|
||||||
|
"nimchacha20poly1305"
|
||||||
|
|
||||||
|
|
||||||
|
requires "nim >= 2.2.4"
|
||||||
8
src/nimble_test.nim
Normal file
8
src/nimble_test.nim
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
# This is just an example to get you started. A typical hybrid package
|
||||||
|
# uses this file as the main entry point of the application.
|
||||||
|
|
||||||
|
import nimble_test/submodule
|
||||||
|
|
||||||
|
when isMainModule:
|
||||||
|
echo(getWelcomeMessage())
|
||||||
|
echo(getWelcomeMessage())
|
||||||
6
src/nimble_test/submodule.nim
Normal file
6
src/nimble_test/submodule.nim
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
# This is just an example to get you started. Users of your hybrid library will
|
||||||
|
# import this file by writing ``import nimble_testpkg/submodule``. Feel free to rename or
|
||||||
|
# remove this file altogether. You may create additional modules alongside
|
||||||
|
# this file as required.
|
||||||
|
|
||||||
|
proc getWelcomeMessage*(): string = "Hello, World!"
|
||||||
1
tests/config.nims
Normal file
1
tests/config.nims
Normal file
@ -0,0 +1 @@
|
|||||||
|
switch("path", "$projectDir/../src")
|
||||||
12
tests/test1.nim
Normal file
12
tests/test1.nim
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
# 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
|
||||||
|
|
||||||
|
import nimble_test/submodule
|
||||||
|
test "correct welcome":
|
||||||
|
check getWelcomeMessage() == "Hello, World!"
|
||||||
Loading…
x
Reference in New Issue
Block a user