$ apt-get update
$ apt-get install -y \
libwebkit2gtk-4.1-dev \
build-essential \
curl \
wget \
file \
libxdo-dev \
libssl-dev \
libayatana-appindicator3-dev \
librsvg2-devsudo pacman -S --needed \
webkit2gtk-4.1 \
base-devel \
curl \
wget \
file \
xdotool \
openssl \
libayatana-appindicator \
librsvg \
socat$ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
$ rustup toolchain install stable
$ curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
$ cargo binstall dioxus-cliConfiguration is loaded from the following paths, in order of priority:
- command line argument
rustpolnak.tomlin current working directory$XDG_CONFIG_HOME/rustpolnak.toml~/.config/rustpolnak.toml
Prerequisites - have nix and devenv in your system:
$ nix shell nixpkgs#devenv to get devenv into your $PATH in a temporary shell
OR
$ nix profile add nixpkgs#devenv to install imperatively to your system
$ devenv shell to enter the dev environment
Optional: automatically enter the environment via direnv
- Have
direnvin your system - On first
cdinto this repository, you may need to calldirenv allowto whitelist this path - On subsequent
cdinto this repository,direnvshould pick up automatically and drop you into adevenv shell
Run the app:
$ devenv up dx
$ cargo run
Start testing API server:
$ devenv up api
Create virtual serials stubs/dev/rfid0 and stubs/dev/rfid1 and begin publishing TAGs:
$ uv run --directory stubs rfid.py
Run rfiddump to test RFID readers:
$ devenv up rfiddump
Run both API and virtual RFID:
$ devenv up api rfid
Run rfiddump to test RFID readers:
$ cargo run --bin rfiddump
$ cargo run --bin rfiddump /dev/ttyUSB0 /dev/ttyUSB1