REVrobotics / node-can-bridge

Other
1 stars 1 forks source link

Update CANBridge #7

Closed NoahAndrews closed 1 year ago

NoahAndrews commented 1 year ago

This PR updates CANBridge by removing the CANBridge source code and artifacts from git, and downloading the CANBridge artifacts at compile time.

LandryNorris commented 1 year ago

By removing the source code here, do we add an extra layer when we make changes to the CANBridge? I'd imagine the process will be recompiling the CANBridge project and uploading the artifact, then future installs will use the new artifact?

NoahAndrews commented 1 year ago

I'd imagine the process will be recompiling the CANBridge project and uploading the artifact, then future installs will use the new artifact?

Mostly correct. The download-CanBridge.mjs script has a canBridgeTag constant that specifies which version of CANBridge will be used. The CANBridge binaries then get bundled with the npm package, so a given node-can-bridge version will always use the same version of CANBridge.

By removing the source code here, do we add an extra layer when we make changes to the CANBridge?

Kind of. Previously, the process for updating CANBridge and releasing those changes to node-can-bridge wasn't really defined. Even though the CANBridge source code used to live in the node-can-bridge repository, it wasn't actually getting built within the node-can-bridge context. Only the precompiled dll and lib files that also used to live in the node-can-bridge repo were being used. So this is in every way a big improvement from the previous status quo.