Skip to content
This repository has been archived by the owner on Jun 19, 2024. It is now read-only.

Commit

Permalink
fix: add pros-cli to flake and minor doc updates
Browse files Browse the repository at this point in the history
  • Loading branch information
Gavin-Niederman committed Jan 1, 2024
1 parent b085f3e commit e99d5d4
Show file tree
Hide file tree
Showing 5 changed files with 85 additions and 7 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@ The steps for getting pros-rs compiling are slightly different based on if you u

#### With Nix

The Nix flake contains the Arm Gnu Toolchain and cargo pros.
Unfortunately pros-cli is not packaged for Nix so you will have to get it from a different package manager.
Nixos users are, unfortunately, out of luck here.
The Nix flake contains the Arm Gnu Toolchain, cargo pros, and pros-cli.

There is a ``.envrc`` file included for Nix + Direnv users.

Expand Down
73 changes: 72 additions & 1 deletion flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,18 @@
inputs = {
flake-utils.url = "github:numtide/flake-utils";
cargo-pros.url = "github:pros-rs/cargo-pros";
pros-cli-nix.url = "github:BattleCh1cken/pros-cli-nix";
};

outputs = { nixpkgs, flake-utils, cargo-pros, ... }:
outputs = { nixpkgs, flake-utils, cargo-pros, pros-cli-nix, ... }:
(flake-utils.lib.eachDefaultSystem (system:
let
pkgs = nixpkgs.legacyPackages.${system};
cargo-pros' = cargo-pros.packages.${system}.default;
pros-cli = pros-cli-nix.packages.${system}.default;
in {
devShell =
pkgs.mkShell { buildInputs = with pkgs; [ gcc-arm-embedded-9 cargo-pros' ]; };
devShell = pkgs.mkShell {
buildInputs = with pkgs; [ gcc-arm-embedded-9 cargo-pros' pros-cli ];
};
}));
}
5 changes: 5 additions & 0 deletions pros/src/async_runtime/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
//! A tiny async runtime.
//!
//! This runtime can be used outside of the main task, but it is reccomended to only use either
//! real FreeRTOS tasks or this async runtime.
use core::future::Future;

use async_task::Task;
Expand Down
1 change: 1 addition & 0 deletions pros/src/error.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
//! Helpers for dealing with errno.
//!
//! Most of the contents of this file are not public.
pub(crate) fn take_errno() -> i32 {
Expand Down

0 comments on commit e99d5d4

Please sign in to comment.