diff --git a/.envrc b/.envrc new file mode 100644 index 0000000..e069170 --- /dev/null +++ b/.envrc @@ -0,0 +1,6 @@ +#!/usr/bin/env sh +# shellcheck shell=sh # POSIX + +# This file is used to provide directory-oriented environment variables and integrations + +use flake diff --git a/.gitignore b/.gitignore index 57231e9..a93b8ba 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ *.fcstd1 *.FCStd1 *.stl +*.FCBak +.direnv/ diff --git a/README.md b/README.md index a8ead63..635190e 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ Krey's fork of base48's large CNC -![cnc](cnc.png "cnc desk") +![cnc](./img/introduction.png "View of the CNC model") diff --git a/base.FCStd b/base.FCStd index 4097969..b4a7a6d 100644 Binary files a/base.FCStd and b/base.FCStd differ diff --git a/cnc.FCStd b/cnc.FCStd index c85e0ef..8c35daa 100644 Binary files a/cnc.FCStd and b/cnc.FCStd differ diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..7326ca6 --- /dev/null +++ b/flake.nix @@ -0,0 +1,53 @@ +{ + description = "Kreyren's Infrastructure Management With NiXium"; + + inputs = { + # Release inputs + nixpkgs-legacy.url = "github:nixos/nixpkgs/nixos-23.05"; + nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11"; + # # nixpkgs.url = "git+file:///home/raptor/src/nixpkgs"; + nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable"; + # nixpkgs-unstable-small.url = "github:nixos/nixpkgs/nixos-unstable"; + nixpkgs-master.url = "github:nixos/nixpkgs/master"; + nixpkgs-staging.url = "github:nixos/nixpkgs/staging"; + }; + + outputs = inputs @ { self, ... }: + inputs.flake-parts.lib.mkFlake { inherit inputs; } { + imports = [ + inputs.flake-root.flakeModule + inputs.mission-control.flakeModule + ]; + + systems = [ "x86_64-linux" "aarch64-linux" "riscv64-linux" ]; + + perSystem = { system, config, ... }: { + # FIXME-QA(Krey): Move this to a separate file somehow? + # FIXME-QA(Krey): Figure out how to shorten the `inputs.nixpkgs-unstable.legacyPackages.${system}` ? + ## _module.args.nixpkgs = inputs.nixpkgs-unstable.legacyPackages.${system}; + ## _module.args.nixpkgs = import inputs.nixpkgs { inherit system; }; + mission-control.scripts = { + freecad = { + description = "FreeCAD (fully integrated)"; + category = "Integrated Editors"; + exec = "${inputs.nixpkgs.legacyPackages.${system}.freecad}/bin/freecad ./default.FCStd"; + }; + }; + devShells.default = inputs.nixpkgs.legacyPackages.${system}.mkShell { + name = "NiXium-devshell"; + nativeBuildInputs = [ + inputs.nixpkgs.legacyPackages.${system}.bashInteractive # For terminal + inputs.nixpkgs.legacyPackages.${system}.nil # Needed for linting + inputs.nixpkgs.legacyPackages.${system}.nixpkgs-fmt # Nixpkgs formatter + inputs.nixpkgs.legacyPackages.${system}.git # Working with the codebase + inputs.nixpkgs.legacyPackages.${system}.fira-code # For liquratures in code editors + ]; + inputsFrom = [ config.mission-control.devShell ]; + # Environmental Variables + #RULES = "./secrets/secrets.nix"; # For ragenix to know where secrets are + }; + + formatter = inputs.nixpkgs.nixpkgs-fmt; + }; + }; +} diff --git a/cnc.png b/img/cnc.png similarity index 100% rename from cnc.png rename to img/cnc.png diff --git a/parts/motors/mount_y.FCStd b/parts/motors/mount_y.FCStd index e73f0fb..6aa8430 100644 Binary files a/parts/motors/mount_y.FCStd and b/parts/motors/mount_y.FCStd differ diff --git a/portal.FCStd b/portal.FCStd index f3e973d..75db96a 100644 Binary files a/portal.FCStd and b/portal.FCStd differ diff --git a/rails.FCStd b/rails.FCStd index 0606a83..979c429 100644 Binary files a/rails.FCStd and b/rails.FCStd differ