mirror of
https://github.com/Alexandre1a/NixOSDots.git
synced 2026-03-10 00:09:46 +01:00
Added a web devflake (currently a copy of the CPP one), uses Go, and the traditional web stack (HTML, JS, CSS)
This commit is contained in:
parent
8f2d90bc48
commit
0c24f90379
3
dev-flakes/web/.envrc
Normal file
3
dev-flakes/web/.envrc
Normal file
@ -0,0 +1,3 @@
|
||||
FLAKEDIR=~/Developer/nix/NixOSDots/dev-flakes
|
||||
|
||||
use flake ${FLAKEDIR}/web
|
||||
49
dev-flakes/web/flake.nix
Normal file
49
dev-flakes/web/flake.nix
Normal file
@ -0,0 +1,49 @@
|
||||
{
|
||||
description = "General C++ dev enviroment";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
};
|
||||
in
|
||||
{
|
||||
packages.default = pkgs.stdenv.mkDerivation {
|
||||
pname = "myapp";
|
||||
version = "0.1.0";
|
||||
src = self;
|
||||
|
||||
nativeBuildInputs = with pkgs; [ cmake ninja ];
|
||||
buildInputs = with pkgs; [ ];
|
||||
};
|
||||
|
||||
devShells.default = pkgs.mkShell {
|
||||
name = "cpp-dev";
|
||||
|
||||
# In the dev shell, you get more tools than just what's needed to build
|
||||
packages = with pkgs; [
|
||||
gcc
|
||||
clang
|
||||
cmake
|
||||
ninja
|
||||
gdb
|
||||
valgrind
|
||||
clang-tools
|
||||
ccache
|
||||
];
|
||||
|
||||
shellHook = ''
|
||||
echo "C++ loaded"
|
||||
export CC="ccache gcc"
|
||||
export CXX="ccache g++"
|
||||
'';
|
||||
};
|
||||
});
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user