Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to NNG 2.0 for NanoRT #1154

Draft
wants to merge 222 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
222 commits
Select commit Hold shift + click to select a range
77c40c3
msg: add sockaddr to message structure
gdamore Oct 6, 2024
76bb3e8
fixes #168 UDP transport
gdamore Oct 6, 2024
8b8aacc
test: support UDP urls for marry
gdamore Oct 6, 2024
5ab46c4
Update README.adoc
jan-ruzicka-c Sep 18, 2024
8633294
README update for development vs. stable
gdamore Oct 6, 2024
81b1d82
posix: add getentropy() based RNG
gdamore Oct 6, 2024
66d1afa
Flag build packages as 2.0.0-dev.
gdamore Oct 6, 2024
bf8e56e
Convert README to markdown
gdamore Oct 6, 2024
8fc6ad7
update comments in README
JaylinYu Feb 18, 2025
1643830
Markup fix (messed up by Prettier).
gdamore Oct 6, 2024
ab2f413
More markup tweak.
gdamore Oct 6, 2024
74c3f2d
docs: Provide migration guidance.
gdamore Oct 6, 2024
f19bfc8
Fix link to migrating
gdamore Oct 6, 2024
016b500
More link fixes
gdamore Oct 6, 2024
194035c
Convert CoC to markdown
gdamore Oct 6, 2024
2d37c1a
Remove the documentation for 3compat.
gdamore Sep 7, 2024
cc0b2a6
Remove the legacy transport registration functions.
gdamore Sep 7, 2024
29faf21
* MDF [tests] disable nng_log_err
JaylinYu Feb 18, 2025
8815e49
Point to NNG 1 migration guide
gdamore Oct 6, 2024
476aa46
Remove deprecated `nng_pipe_getopt` and friends.
gdamore Sep 7, 2024
761c4af
Remove unused legacy nng_closeall.
gdamore Oct 6, 2024
de9ae1a
Drop unused nng_msg_getopt
gdamore Sep 7, 2024
12a7f21
Remove dialer legacy option functions
gdamore Sep 7, 2024
dcb7fd9
Drop the legacy listener option functions
gdamore Sep 7, 2024
82f2939
Remove deprecated context option functions.
gdamore Sep 7, 2024
d2d15ad
Remove the last of the legacy option handling functions.
gdamore Sep 7, 2024
339e1b0
fixup README stuff
gdamore Oct 6, 2024
3051c24
idmap public docs converted to mdbook
gdamore Oct 6, 2024
2717424
Docs for mutexes converted.
gdamore Oct 6, 2024
1d2ebb7
Remove old idmap and mutex docs
gdamore Oct 6, 2024
8d35b00
Convert nng_clock and nng_msleep docs to mdbook
gdamore Oct 7, 2024
23ed350
Remove asciidoc nng_clock and nng_msleep
gdamore Oct 7, 2024
9c7a463
Style fix for nng_msleep
gdamore Oct 7, 2024
f685fa1
Initial swag at UDP transport docs, also converted socket transport t…
gdamore Oct 7, 2024
007dd24
Fix UDP port numbers in docs
gdamore Oct 7, 2024
d395dfe
Forgot to add the UDP man page!
gdamore Oct 7, 2024
f831975
Add missing description header to socket manual
gdamore Oct 7, 2024
78a0c02
Convert nng_random to new format.
gdamore Oct 7, 2024
cd54db0
nng_version converted to mdbook
gdamore Oct 7, 2024
fea0e85
Convert nng_alloc and nng_free to mdbook.
gdamore Oct 7, 2024
e2fcce3
Indexing improvements to mdbook docs.
gdamore Oct 7, 2024
8da27fb
Minor markup fix for some mdbook pages.
gdamore Oct 7, 2024
babc824
Convert nng_strerror to mdbook.
gdamore Oct 7, 2024
40aaa98
Minor indexing markup fix
gdamore Oct 7, 2024
fb3414e
Fix indexing for nng_strerror.md.
gdamore Oct 7, 2024
014ba41
Converted nng_strdup and nng_strfree to mdbook.
gdamore Oct 7, 2024
0481a77
Bump checkout action to v4.
gdamore Oct 7, 2024
8a743fa
Actually enable UDP. Also fix some UWYI includes.
gdamore Oct 7, 2024
18566a3
Bump codecov to v4
gdamore Oct 7, 2024
4d77845
Fix case for infinite sleep.
gdamore Oct 7, 2024
d054d74
Finally, actually register the UDP transport.
gdamore Oct 7, 2024
6e0916c
Missed another instance of codecov-action@v1
gdamore Oct 7, 2024
0989569
Missed config option for UDP
gdamore Oct 7, 2024
f376380
udp: fix leaks on EP destroy
gdamore Oct 7, 2024
0fd7ec8
Converted condition variable docs to mdbook.
gdamore Oct 12, 2024
15c04c8
Convert nng_socket_pair.
gdamore Oct 12, 2024
9a352f2
more mdbook stuff
gdamore Oct 12, 2024
5cb5edf
Add missing nng_socket_pair.md
gdamore Oct 12, 2024
0b84bdd
Convert thread documentation to mdbook. Also conslidate this man page.
gdamore Oct 12, 2024
7330340
nng_opts_parse converted to mdbook.
gdamore Oct 12, 2024
aa5e65c
Add ref for nng_opts_parse
gdamore Oct 12, 2024
2952857
Convert nng_duration to mdbook.
gdamore Oct 12, 2024
172e18f
Fix internal link for nng_opts_parse.
gdamore Oct 12, 2024
dfd29ee
Convert inproc doc to mdbook.
gdamore Oct 12, 2024
639bfdb
nng_msg docs converted to mdbook
gdamore Oct 12, 2024
f0685e7
nng message header converted to mdbook
gdamore Oct 12, 2024
04a535c
nng_msg_header and company converted to mdbook
gdamore Oct 12, 2024
6364059
Minor fixes to mdbook docs.
gdamore Oct 12, 2024
841ee9a
UDP: add some statistics
gdamore Oct 12, 2024
522efdd
Fix code coverage in README, hopefully
gdamore Oct 12, 2024
1e27eaf
stats: Reduce the need for NNG_ENABLE_STATS checks everywhere.
gdamore Oct 13, 2024
fe55104
UDP: numerous fixes, added test for copy break
gdamore Oct 13, 2024
df916ab
UDP: burst testing to improve coverage
gdamore Oct 13, 2024
7cf50fa
UDP/sanitizer: Don't be strict about message loss in sanitizer or cov…
gdamore Oct 13, 2024
ee77f94
udp: fix race, fix tests
gdamore Oct 13, 2024
65d4e9e
UDP: More test tuning for lossy environments.
gdamore Oct 13, 2024
2e69859
mdbook: Add some front matter material.
gdamore Oct 13, 2024
1eaa95c
Fix some intradoc links.
gdamore Oct 13, 2024
2c73231
stats: Reduce some wasted space for disabled stats.
gdamore Oct 13, 2024
ddf2474
fixes #1890 stats could support an inline lock - remove most atomics
gdamore Oct 13, 2024
ef2c21f
docs: nng_msg_pipe converted to mdbook
gdamore Oct 14, 2024
cad6d89
docs: Fix prototype and description for nng_msg_realloc.
gdamore Oct 14, 2024
063328c
Forgot to commit nng_msg_pipe
gdamore Oct 14, 2024
c94e266
doc: nng_url converted to mdbook.
gdamore Oct 14, 2024
c996982
Converted protocols to mdbook.
gdamore Oct 15, 2024
453045f
log documentation converted to mdbook.
gdamore Oct 15, 2024
16573b1
Minor fixes for () in docs
gdamore Oct 15, 2024
43d7f32
docs: nng_log_get_level has a return value
gdamore Oct 15, 2024
fc51c66
Stats API converted to mdbook.
gdamore Oct 16, 2024
e42c835
markup fix in index
gdamore Oct 16, 2024
0954b3a
Forgot to add log index doc
gdamore Oct 19, 2024
06be9ff
IPC transport converted to mdbook.
gdamore Oct 19, 2024
47416ca
aio cancellation docs converted to mdbook
gdamore Oct 19, 2024
9f5415d
Conversion of nng_aio to mdbook in progress
gdamore Oct 19, 2024
85b7a20
Logging as a single chapter.
gdamore Oct 19, 2024
04a4b4e
Add syslog RFCs to see also
gdamore Oct 19, 2024
f357031
docs: statistics as a single chapter.
gdamore Oct 19, 2024
3981e21
Synchronization primitives made a single chapter in mdbook.
gdamore Oct 20, 2024
85daf42
Use `const` for nng_stat when possible.
gdamore Oct 21, 2024
1ee6298
docs: thread converted to new style
gdamore Oct 21, 2024
a77e447
Forgot to commit synch.md
gdamore Oct 21, 2024
f963d3e
docs: Move time related functions into single chapter.
gdamore Oct 21, 2024
a1ecd7a
docs: fix clock cross references
gdamore Oct 21, 2024
6523a41
remove legacy support for configuration of transport options on socket
gdamore Oct 21, 2024
90783cb
doc: remove unused index.md for thr/
gdamore Oct 22, 2024
020285a
docs: messages API converted to single chapter.
gdamore Oct 22, 2024
af210a7
docs: move migration docs into book
gdamore Oct 22, 2024
db7f423
fix typo
gdamore Oct 22, 2024
f631153
docs: fix markup snafu in msgm.md
gdamore Oct 22, 2024
a5a5fe2
docs: add memory chapter
gdamore Oct 22, 2024
3b6387c
docs: consolidate misc chapter
gdamore Oct 22, 2024
acfbf00
docs: idmap into its own chapter
gdamore Oct 23, 2024
f056c74
docs: URL chapter
gdamore Oct 23, 2024
0ca59cb
docs: master cross-reference table
gdamore Oct 23, 2024
224981b
Remove the libnanomsg compatibility layer
gdamore Oct 23, 2024
ad096ba
docs: document error codes
gdamore Oct 24, 2024
6c3a23c
docs: nng_opts_parse converted to chapter.
gdamore Oct 24, 2024
9780b49
docs: AIO chapter (consumer only) converted to mdbook.
gdamore Oct 25, 2024
e3d5965
docs: update nng_sleep_aio for mdbook
gdamore Oct 27, 2024
92722cd
disable nng log
JaylinYu Feb 18, 2025
d38dbe2
mdbook action (trial) for publish
gdamore Oct 27, 2024
39bfcc5
fix mdbook (try 1)
gdamore Oct 27, 2024
7383d91
fix mdbook (try 2)
gdamore Oct 27, 2024
ce8526c
fix mdbook (try 3)
gdamore Oct 27, 2024
a15a1fb
Need mdbook plugins
gdamore Oct 27, 2024
f12c805
Fix publish dir
gdamore Oct 27, 2024
ea53d99
docs: fix various links
gdamore Oct 27, 2024
62f6489
docs: fix message links
gdamore Oct 27, 2024
b8f2566
Reenable jekyll
gdamore Oct 27, 2024
b698133
README doc links
gdamore Oct 27, 2024
e2d4e05
tls: Remove the individual TLS configuration options
gdamore Oct 28, 2024
b61dcbe
tls: move definitions to core nng.h
gdamore Oct 28, 2024
d5facc5
fix confilicts
JaylinYu Feb 18, 2025
929c373
streams: drop some stream set functions
gdamore Oct 28, 2024
6f3bcd9
Remove nng_stream_set function family.
gdamore Oct 28, 2024
b24f5de
NNI_GETXX macros are brittle due to casting mistake.
gdamore Nov 2, 2024
df6b801
NNG_OPT_RECVFD and NNG_OPT_SENDFD converted to functions.
gdamore Nov 2, 2024
5f21077
adapt to new NNG fd pollable
JaylinYu Feb 18, 2025
53b92a2
* FIX adapt to breaking change of NNG 2.0 on tls
JaylinYu Feb 18, 2025
96d6c28
Remove nng_ctx/socket_set/get_addr
gdamore Nov 3, 2024
f9080e6
Remove unused compat CMakeLists.txt
gdamore Nov 3, 2024
27801ae
Replace `NNG_OPT_PROTO`, `NNG_OPT_PROTONAME`, and friends with functi…
gdamore Nov 3, 2024
3b456c1
* FIX conflicts between 1.10 and 2.0
JaylinYu Feb 18, 2025
256b7f0
Replace `NNG_OPT_RAW` with `nng_socket_raw`.
gdamore Nov 3, 2024
447c621
Replace NNG_OPT_SUB_SUBSCRIBE/UNSUBSCRIBE with functions.
gdamore Nov 3, 2024
02dabe7
Add some more tests for sub coverage.
gdamore Nov 3, 2024
ea639c9
Remove untyped nng_pipe_get, support for untyped sockaddr set.
gdamore Nov 3, 2024
e1766bc
Remove untyped stream option functions.
gdamore Nov 3, 2024
ed5b37d
* FIX conflicts
JaylinYu Feb 18, 2025
c61cad0
Remove untyped nng_dialer_get/set and nng_listener_get/set.
gdamore Nov 3, 2024
5af670b
replace nng_listener_set with nng_listener_set_ptr
JaylinYu Feb 18, 2025
85d23d0
Remove nng_ctx untyped option functions
gdamore Nov 3, 2024
e97d671
Remove untyped nng_dialer_get/set and nng_listener_get/set.
gdamore Nov 3, 2024
6525a5a
Remove untyped nng_socket_get and nng_socket_set.
gdamore Nov 3, 2024
644c4b4
Remove NNI_TYPE_OPAQUE altogether.
gdamore Nov 3, 2024
09f0f45
Socket option handling clean ups for endpoints.
gdamore Nov 3, 2024
d714da9
* FIX [quic] adapt to new copyin_str
JaylinYu Feb 19, 2025
7f26cbb
* MDF [transport] adapt to new set_ptr
JaylinYu Feb 19, 2025
77192a7
* MDF [transport] use nni_copyin_ptr
JaylinYu Feb 19, 2025
318cf79
Update acutest.h.
gdamore Nov 4, 2024
1cb87f6
Introduce NUTS_SKIP and use it in a few tests.
gdamore Nov 4, 2024
aa4a1ea
Remove left over prototype for nng_socket_get()
gdamore Nov 4, 2024
096ec99
UDP test improvements.
gdamore Nov 4, 2024
1d14d3b
* MDF [test] swap log api
JaylinYu Feb 19, 2025
3c28575
Use a callback for UDP burst test.
gdamore Nov 5, 2024
30b6c00
UDP: prefer new packets (drop older)
gdamore Nov 5, 2024
b0e3e2f
Add pubdrop test.
gdamore Nov 5, 2024
e5f6679
Remove registration functions (unused).
gdamore Nov 5, 2024
f8771c8
IPC test - note which ones skipped.
gdamore Nov 5, 2024
7fa76c5
ipc: validate stale cleanup listener
gdamore Nov 5, 2024
40a5156
Fix leak in pubdrop
gdamore Nov 5, 2024
153b2e6
ipc: listener cancellation test
gdamore Nov 6, 2024
416978a
remove nni_plat_println - we have nni_plat_printf which is good enough
gdamore Nov 6, 2024
257aa7b
Add zero test for error
gdamore Nov 6, 2024
a77864d
websocket: fix for setting user headers
gdamore Nov 6, 2024
09492c1
remove nni_plat_println in platform.h
JaylinYu Feb 19, 2025
8d8eb2c
fix logging conflicts
JaylinYu Feb 19, 2025
8a5a511
Fix coverage badge.
gdamore Nov 6, 2024
435c104
Remove unused sockaddr NULL check
gdamore Nov 7, 2024
a0302ae
wolfSSL: fix configuration to match official wolfSSL cmake library
gdamore Nov 8, 2024
62f05fd
Add matrix of TLS engines, including wolfSSL
gdamore Nov 8, 2024
784e16d
Remove left over single doc pages.
gdamore Nov 9, 2024
8359ce0
fixes #1914 Document nng_socket_proto_id, proto_name, peer_id, peer_n…
gdamore Nov 9, 2024
d427b8c
Remove tabs from docs (expand to 4 spaces) - some renderers cannot cope.
gdamore Nov 9, 2024
46a4268
Remove references to NNG_OPT_SUB_SUBSCRIBE.
gdamore Nov 9, 2024
def4684
Add some cross references in the NNG 1 migration guide.
gdamore Nov 9, 2024
005d70b
fixes #1907 Document the nng_socket_get_send_poll_fd and recv_poll_fd
gdamore Nov 9, 2024
098defc
Add some examples for generating PDF and EPUB.
gdamore Nov 9, 2024
f174630
TLS configuration changed to use discret _set_tls and _get_tls functi…
gdamore Nov 9, 2024
4b65bd9
* MDF [tls/global] adapt to new TLS config method
JaylinYu Feb 21, 2025
76bd3c2
websocket: Do not allow a listener or dialer to change TLS while running
gdamore Nov 10, 2024
8943cec
refactor initialization/finalization
gdamore Nov 10, 2024
5163da6
* MDF [transport/protocol] remove NNG_ELIDE_DEPRECATED in customized …
JaylinYu Feb 24, 2025
f7796c7
* MDF [mqtt/headers] remove NNG_ELIDE_DEPRECATED & compatible with NN…
JaylinYu Feb 24, 2025
608176d
Migration update referencing nng_init (but note not documented yet.)
gdamore Nov 10, 2024
9b410a4
Cleanup POSIX platform initialization.
gdamore Nov 11, 2024
6005586
init test coverage improvements
gdamore Nov 11, 2024
4b47076
Document nng_init and nng_fini
gdamore Nov 11, 2024
2218474
tls: remove support for TLS 1.0 and 1.1.
gdamore Nov 16, 2024
233aa85
tls: add ecdsa test case
gdamore Nov 17, 2024
ca605fb
remove NNG_OPT_SOCKNAME (and socket names altogether)
gdamore Nov 17, 2024
02c3855
tcp/tls: Remove support for local interface address in dialer URLs
gdamore Nov 17, 2024
db42f8f
fix parsing bug in abstract URLs
gdamore Nov 17, 2024
f72896d
intern URL scheme
gdamore Nov 17, 2024
d4a810b
* NEW [url] add NanoNNG url into new url schema matrix
JaylinYu Feb 25, 2025
2e440b8
URL u_port should be a number not a string.
gdamore Nov 18, 2024
fbc624a
nni_url_sprintf
gdamore Nov 18, 2024
4382343
More url work. Undocument rawurl, and stop using it stats and logs.
gdamore Nov 18, 2024
7f4495b
URL refactor part 1.
gdamore Nov 18, 2024
14c3e4f
Merge internal and external URL APIs. No need for
gdamore Nov 19, 2024
034ed54
Introduce accessors for nng_url struct and make it opaque.
gdamore Nov 19, 2024
32aa8bc
url: Use NNG_EINVAL for parse failures
gdamore Nov 19, 2024
673e3be
Add new nni_url_parse_inline, and add more test cases for coverage.
gdamore Nov 19, 2024
9ef2048
TCPv6 test suite fixes for addresses.
gdamore Nov 19, 2024
176a82e
Avoid extra allocs for listener url.
gdamore Nov 22, 2024
b8ed8bf
Use 32-bit port numbers.
gdamore Nov 22, 2024
2fa887a
* MDF [url] replace nni_url with nng_url
JaylinYu Feb 25, 2025
090359d
Collect the bound port as part of the URL at bind time.
gdamore Nov 22, 2024
0db2fa5
Inline dialer URL.
gdamore Nov 22, 2024
013a7cb
Introduce nng_listener_get_url and nng_dialer_get_url.
gdamore Nov 22, 2024
50222d9
fix rebase error
JaylinYu Feb 25, 2025
4cff23f
* FIX missing cmakelist change
JaylinYu Feb 25, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
43 changes: 21 additions & 22 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -1,38 +1,37 @@
name: coverage
on: [push]
jobs:

linux-coverage:
name: linux
runs-on: [ ubuntu-latest ]
runs-on: [ubuntu-latest]
steps:
- name: Check out code
uses: actions/checkout@v1
- name: Check out code
uses: actions/checkout@v4

- name: Install mbedTLS
run: sudo apt-get install libmbedtls-dev
- name: Install mbedTLS
run: sudo apt-get install libmbedtls-dev

- name: Install ninja
run: sudo apt-get install ninja-build
- name: Install ninja
run: sudo apt-get install ninja-build

- name: Configure
run: mkdir build && cd build && cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug -DNNG_ENABLE_COVERAGE=ON -DNNG_ENABLE_TLS=ON ..
- name: Configure
run: mkdir build && cd build && cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug -DNNG_ENABLE_COVERAGE=ON -DNNG_ENABLE_TLS=ON ..

- name: build
run: cd build && ninja
- name: build
run: cd build && ninja

- name: Test
run: cd build && ctest --output-on-failure
- name: Test
run: cd build && ctest --output-on-failure

- name: Upload report
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
yml: ./.codecov.yml
- name: Upload report
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
codecov_yml_path: ./.codecov.yml

darwin-coverage:
name: darwin
runs-on: [ macos-latest ]
runs-on: [macos-latest]
steps:
- name: Check out code
uses: actions/checkout@v1
Expand All @@ -44,7 +43,7 @@ jobs:
run: brew install ninja

- name: Configure
run: mkdir build && cd build && cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug -DNNG_ENABLE_COVERAGE=ON -DNNG_ENABLE_TLS=ON ..
run: mkdir build && cd build && cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug -DNNG_ENABLE_COVERAGE=ON -DNNG_ENABLE_TLS=ON ..

- name: build
run: cd build && ninja
Expand All @@ -53,7 +52,7 @@ jobs:
run: cd build && ctest --output-on-failure

- name: Upload report
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
yml: ./.codecov.yml
2 changes: 1 addition & 1 deletion .github/workflows/darwin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
runs-on: [macos-latest]
steps:
- name: Check out code
uses: actions/checkout@v1
uses: actions/checkout@v4

- name: Install Mbed TLS
run: brew install mbedtls
Expand Down
36 changes: 22 additions & 14 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,33 @@
name: linux
on: [push, pull_request]
jobs:

build:
strategy:
matrix:
tls:
- engine: mbed
pkg: libmbedtls-dev
dir: build.mbed
- engine: wolf
pkg: libwolfssl-dev
dir: build.wolf
name: build
runs-on: [ ubuntu-latest ]
runs-on: [ubuntu-latest]
steps:
- name: Check out code
uses: actions/checkout@v1
- name: Check out code
uses: actions/checkout@v4

- name: Install mbedTLS
run: sudo apt-get install libmbedtls-dev
- name: Install ninja
run: sudo apt-get install ninja-build

- name: Install ninja
run: sudo apt-get install ninja-build
- name: Install TLS engine
run: sudo apt-get install ${{ matrix.tls.pkg }}

- name: Configure
run: mkdir build && cd build && cmake -G Ninja -D NNG_ENABLE_TLS=ON ..
- name: Configure
run: mkdir ${{ matrix.tls.dir }} && cd ${{ matrix.tls.dir }} && cmake -G Ninja -D NNG_ENABLE_TLS=ON -DNNG_TLS_ENGINE=${{ matrix.tls.engine }} ..

- name: Build
run: cd build && ninja
- name: Build
run: cd ${{ matrix.tls.dir }} && ninja

- name: Test
run: cd build && ctest --output-on-failure
- name: Test
run: cd ${{ matrix.tls.dir }} && ctest --output-on-failure
36 changes: 36 additions & 0 deletions .github/workflows/mdbook.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: mdbook

on:
push:
branches:
- main
pull_request:

jobs:
deploy:
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
steps:
- uses: actions/checkout@v4

- name: Setup mdBook
uses: peaceiris/actions-mdbook@v2
with:
# mdbook-version: '0.4.10'
mdbook-version: "latest"

- run: cargo install mdbook-alerts
- run: cargo install mdbook-indexing
- run: cargo install mdbook-footnote
- run: cargo install mdbook-pagetoc
- run: mdbook build -d ./book docs

- name: Deploy
uses: peaceiris/actions-gh-pages@v4
if: ${{ github.ref == 'refs/heads/main' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/book
destination_dir: ./ref
enable_jekyll: true
2 changes: 1 addition & 1 deletion .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
runs-on: [windows-latest]
steps:
- name: Check out code
uses: actions/checkout@v1
uses: actions/checkout@v4

- name: vcpkg build
id: vcpkg
Expand Down
14 changes: 7 additions & 7 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,10 @@ set(NNG_MINOR_VERSION ${CMAKE_MATCH_1})
string(REGEX MATCH "NNG_PATCH_VERSION ([0-9]*)" _ ${nng_ver_h})
set(NNG_PATCH_VERSION ${CMAKE_MATCH_1})
string(REGEX MATCH "NNG_RELEASE_SUFFIX \"([a-z0-9]*)\"" _ ${nng_ver_h})
if (NOT ("${CMAKE_MATCH_1}" STREQUAL ""))
set(NNG_PRERELEASE "-${CMAKE_MATCH_1}")
set(NNG_DEV_VERSION ${CMAKE_MATCH_1})
if (NNG_DEV_VERSION)
message(STATUS "This is a prelease.")
set(NNG_PRERELEASE "-${NNG_DEV_VERSION}")
endif ()

set(NNG_ABI_SOVERSION 1)
Expand Down Expand Up @@ -99,10 +101,6 @@ target_compile_definitions(nng_private INTERFACE NNG_PRIVATE)
if (NNG_ELIDE_DEPRECATED)
target_compile_definitions(nng PRIVATE NNG_ELIDE_DEPRECATED)
endif()
if (NNG_ENABLE_COMPAT)
target_compile_definitions(nng PRIVATE NNG_ENABLE_COMPAT)
endif()


# We can use rlimit to configure the stack size for systems
# that have too small defaults. This is not used for Windows,
Expand Down Expand Up @@ -180,7 +178,8 @@ endif ()
include(CheckSanitizer)
CheckSanitizer()
if (NOT NNG_SANITIZER STREQUAL "none")
set(NNG_SANITIZER_FLAGS "-g -fsanitize=${NNG_SANITIZER}")
set(NNG_SANITIZER_FLAGS "-fsanitize=${NNG_SANITIZER}")
add_definitions(-DNNG_SANITIZER)
endif ()


Expand All @@ -204,6 +203,7 @@ if (NNG_ENABLE_COVERAGE)
else ()
message(FATAL_ERROR "Unable to enable coverage for your compiler.")
endif ()
add_definitions(-DNNG_CONVERAGE)
endif ()

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${NNG_WARN_FLAGS} ${NNG_COVERAGE_C_FLAGS} ${NNG_SANITIZER_FLAGS}")
Expand Down
36 changes: 18 additions & 18 deletions CODE_OF_CONDUCT.adoc → CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
= NNG Code of Conduct
# NNG Code of Conduct

== Our Pledge
## Our Pledge

In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
Expand All @@ -10,29 +10,29 @@ experience,
nationality, personal appearance, race, religion, or sexual identity and
orientation.

== Our Standards
## Our Standards

Examples of behavior that contributes to creating a positive environment
include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
- Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or
- The use of sexualized language or imagery and unwelcome sexual attention or
advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic
- Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or electronic
address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a
- Other conduct which could reasonably be considered inappropriate in a
professional setting

== Our Responsibilities
## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
Expand All @@ -44,7 +44,7 @@ that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.

== Scope
## Scope

This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
Expand All @@ -53,7 +53,7 @@ address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.

== Enforcement
## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at [email protected]. All
Expand All @@ -67,8 +67,8 @@ Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

== Attribution
## Attribution

This Code of Conduct is adapted from the
https://www.contributor-convent.org[Contributor Covenant], version 1.4,
[Contributor Covenant](https://www.contributor-convent.org), version 1.4,
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
Loading
Loading