Skip to content

Commit e387285

Browse files
authored
copy irsdk-node to the repo (#12)
1 parent 1fc7e16 commit e387285

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+14992
-751
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -41,14 +41,7 @@ jobs:
4141
4242
- name: Install dependencies
4343
if: steps.cache-deps.outputs.cache-hit != 'true'
44-
run: |
45-
npm ci --ignore-scripts
46-
npm run prepare
47-
npm rebuild
48-
49-
- name: Apply patches and rebuild
50-
if: steps.cache-deps.outputs.cache-hit == 'true'
51-
run: npm run prepare
44+
run: npm ci
5245

5346
- name: Run linting
5447
run: npm run lint

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,3 +99,7 @@ asset-data
9999

100100
# should be generated with script
101101
src/**/tracks/tracks.json
102+
103+
# native build
104+
build/
105+
bin/

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ This project is still in the early stages of development, so there may be bugs a
1818

1919
## Introduction
2020

21-
This project is built with React and Electron and uses ths iRacing SDK via [irsdk-node](https://github.com/bengsfort/irsdk-node) library to retrieve data from the iRacing live telemetry memory-map.
21+
This project is built with React and Electron and uses the iRacing SDK to retrieve data from the iRacing live telemetry memory-map.
2222

2323
## Installation
2424

@@ -87,6 +87,7 @@ irdashies/
8787
```
8888

8989
- `src/app/` contains the main Electron application code.
90+
- `src/app/irsdk/` contains the iRacing SDK code including the native C++ bindings.
9091
- `src/frontend/` contains the React components for the overlays.
9192
- `src/types/` contains TypeScript type definitions shared between the frontend and backend (e.g. telemetry types).
9293

binding.gyp

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
{
2+
"targets": [
3+
{
4+
"target_name": "irsdk_node",
5+
"sources": [],
6+
"defines": [
7+
"NAPI_DISABLE_CPP_EXCEPTIONS",
8+
],
9+
"include_dirs": [
10+
"<!(node -p \"require('node-addon-api').include_dir\")",
11+
],
12+
"conditions": [
13+
[
14+
"OS=='win'",
15+
{
16+
"sources": [
17+
"src/app/irsdk/native/irsdk_node.cc",
18+
"src/app/irsdk/native/lib/irsdk_utils.cpp",
19+
"src/app/irsdk/native/lib/yaml_parser.cpp",
20+
"src/app/irsdk/native/lib/irsdk_defines.h",
21+
]
22+
},
23+
]
24+
],
25+
}
26+
]
27+
}

0 commit comments

Comments
 (0)