commit b0e1d5fd3d8332764a1e207de8c4729d307e28d7 Author: th3r00t Date: Thu Aug 28 10:23:32 2025 -0400 Initial push diff --git a/.envrc b/.envrc new file mode 100644 index 0000000..3550a30 --- /dev/null +++ b/.envrc @@ -0,0 +1 @@ +use flake diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..e4fbf8e --- /dev/null +++ b/flake.nix @@ -0,0 +1,37 @@ +{ + description = "chess_interface Development Environment"; + + inputs = { + nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable"; + rust-overlay.url = "github:oxalica/rust-overlay"; + flake-utils.url = "github:numtide/flake-utils"; + }; + + outputs = { self, nixpkgs, rust-overlay, flake-utils, ... }: + let + system = "x86_64-linux"; + overlays = [ (import rust-overlay) ]; + pkgs = import nixpkgs { + inherit system overlays; + }; + in { + devShells."${system}".default = let + pkgs = import nixpkgs { inherit system; }; + in pkgs.mkShell { + packages = with pkgs; [ + rustc + cargo + rust-analyzer + postgresql + adminer + ]; + shellHook = '' + cargo build + echo "Welcome to the chess_interface development environment!" + echo "Available commands:" + echo " - To start PostgreSQL: sudo service postgresql start" + echo " - To access Adminer: adminer --server localhost --username your_username --db your_database" + ''; + }; + }; +}