generated from lf-lang/lf-pico-template
-
Notifications
You must be signed in to change notification settings - Fork 1
/
shell.nix
42 lines (41 loc) · 839 Bytes
/
shell.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{ pkgs ? import <nixpkgs> {} } :
let
# lf = pkgs.callPackage ./nix/lf.nix {};
# lingo = pkgs.callPackage ./nix/lingo.nix {};
in
pkgs.mkShell {
packages = with pkgs; [
picotool
cmake
gcc-arm-embedded
openocd
git
nodejs
zellij
screen
gdb
#fzf
];
buildInputs = [
# lf
# lingo
];
# TODO: integrate dependencies into nix
shellHook = ''
echo "[shell] hook start"
echo "[shell] setup pico-sdk"
git submodule update --init
cd pico-sdk/
git submodule update --init
export PICO_SDK_PATH="$PWD"
cd ../
echo "[shell] copy robot header"
# FIXME: Is this needed?
cp robot-lib/pololu_3pi_2040_robot.h pico-sdk/src/boards/include/boards/
echo "[shell] setup testbed"
cd test/
npm install
echo "[shell] hook end"
cd ../
'';
}