Skip to content

Commit 4cae199

Browse files
authored
Merge branch 'main' into wann/fix_reading_subtype
2 parents e247c8e + 847eebe commit 4cae199

File tree

9 files changed

+13
-7
lines changed

9 files changed

+13
-7
lines changed

.github/workflows/formatting.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
- name: Install Node.js
1919
uses: actions/setup-node@v3
2020
with:
21-
node-version: '20.x'
21+
node-version: '22.x'
2222
cache: 'yarn'
2323

2424
- run: yarn install

.github/workflows/node.js.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
matrix:
2727
os: [ubuntu-latest, windows-latest, macos-latest]
2828
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
29-
node-version: [18.x, 20.x, 21.x]
29+
node-version: [18.x, 20.x, 22.x]
3030

3131
steps:
3232
- name: Checkout Code

.github/workflows/publish-to-npm.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
- name: Install Node.js
1818
uses: actions/setup-node@v4
1919
with:
20-
node-version: '20.x'
20+
node-version: '22.x'
2121
registry-url: 'https://registry.npmjs.org'
2222
cache: 'yarn'
2323

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nbsdecoder.js",
3-
"version": "0.4.4",
3+
"version": "0.4.6",
44
"description": "Node.js module for interacting with NUClear Binary Stream files",
55
"main": "nbsdecoder.js",
66
"types": "nbsdecoder.d.ts",

src/Encoder.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,8 @@ namespace nbs {
108108

109109
auto path = info[0].As<Napi::String>().Utf8Value();
110110

111-
outputFile = std::make_unique<std::ofstream>(path);
112-
indexFile = std::make_unique<zstr::ofstream>(path + ".idx");
111+
outputFile = std::make_unique<std::ofstream>(path, std::ios_base::binary);
112+
indexFile = std::make_unique<zstr::ofstream>(path + ".idx", std::ios_base::binary);
113113
}
114114

115115
Napi::Value Encoder::Write(const Napi::CallbackInfo& info) {

src/Hash.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
21
#include "Hash.hpp"
32

3+
#include <stdexcept>
4+
45
namespace nbs {
56

67
namespace hash {

src/Hash.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#ifndef HASH_HPP
22
#define HASH_HPP
33

4+
#include <cstdint>
45
#include <napi.h>
56

67
#include "third-party/xxhash/xxhash.h"

src/Packet.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11

22
#include "Packet.hpp"
33

4+
#include <stdexcept>
5+
46
namespace nbs {
57

68
Packet Packet::FromJsValue(const Napi::Value& jsPacket, const Napi::Env& env) {

src/Timestamp.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11

22
#include "Timestamp.hpp"
33

4+
#include <stdexcept>
5+
46
namespace nbs {
57

68
namespace timestamp {

0 commit comments

Comments
 (0)