rushabhcodes/wireless-split-keyboard

Wireless Split Keyboard — custom routed nRF52840 split PCBs with a printable enclosure

Version
0.4.5
License
unset
Stars
0

Use with the tscircuit CLI

tsci is the tscircuit CLI. Install it with npm install -g tscircuit.

tsci clone rushabhcodes/wireless-split-keyboard  # download the package files into ./wireless-split-keyboard
tsci add rushabhcodes/wireless-split-keyboard    # add it to your project as @tsci/rushabhcodes.wireless-split-keyboard

In a cloned or new (tsci init) project: tsci dev starts a local preview, tsci build outputs Circuit JSON, and tsci push publishes to tscircuit.com.

scripts/prepare-cloud-dependencies.ts

/** Cloud images link bundled packages outside the project, bypassing project patches. */
import { readFileSync, rmSync } from 'node:fs'
import { resolve } from 'node:path'

const project = JSON.parse(readFileSync('package.json', 'utf8'))
if (project.name !== 'wireless-split-keyboard') throw new Error('Unexpected project directory')
// node_modules is generated. Removing links here never removes their external targets.
rmSync(resolve('node_modules'), { recursive: true, force: true })
const install = Bun.spawn([process.execPath, 'install', '--frozen-lockfile'], {
  stdout: 'inherit', stderr: 'inherit',
})
if (await install.exited !== 0) throw new Error('Clean project dependency installation failed')
console.log('Installed isolated project dependencies, including pinned package patches')