-
-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into feat/cleanup-v3
- Loading branch information
Showing
119 changed files
with
4,562 additions
and
483 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ | |
/.pre-commit-config.yaml | ||
result | ||
interpreter | ||
__pycache__ | ||
__pycache__ | ||
*.egg-info |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
queue_rules: | ||
- name: default | ||
merge_conditions: | ||
- check-success=buildbot/nix-eval | ||
defaults: | ||
actions: | ||
queue: | ||
allow_merging_configuration_change: true | ||
method: rebase | ||
pull_request_rules: | ||
- name: merge using the merge queue | ||
conditions: | ||
- base=main | ||
- label~=merge-queue|dependencies | ||
actions: | ||
queue: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
{ | ||
description = "My flake with dream2nix packages"; | ||
|
||
inputs = { | ||
dream2nix.url = "github:nix-community/dream2nix"; | ||
nixpkgs.url = "nixpkgs/nixos-unstable"; | ||
}; | ||
|
||
outputs = inputs @ { | ||
self, | ||
dream2nix, | ||
nixpkgs, | ||
... | ||
}: let | ||
system = "x86_64-linux"; | ||
lib = nixpkgs.lib; | ||
in { | ||
# all packages defined inside ./packages/ | ||
packages = let | ||
module = { | ||
config, | ||
lib, | ||
dream2nix, | ||
... | ||
}: { | ||
imports = [ | ||
dream2nix.modules.dream2nix.groups | ||
]; | ||
|
||
# Overrides for all package sets | ||
overrides = {}; | ||
|
||
# We can define various package sets | ||
groups = { | ||
non-overridden-set = { | ||
overrides = lib.mkForce {}; | ||
}; | ||
# By default, a set has a packages attribute. | ||
# Additional modules can add support for creating environments. | ||
python-set = { | ||
overrides = {}; | ||
devShell = {}; | ||
packages = {}; | ||
}; | ||
nodejs-set = { | ||
# ... | ||
}; | ||
|
||
final-set = { | ||
imports = [ | ||
dream2nix.modules.dream2nix.packages | ||
dream2nix.modules.dream2nix.python-packages | ||
dream2nix.modules.dream2nix.symlinked-env | ||
dream2nix.modules.dream2nix.dev-shell | ||
]; | ||
packages = { | ||
inherit | ||
(config.groups.python-set) | ||
requests | ||
aiohttp | ||
; | ||
}; | ||
symlinked-env = {type = "derivation";}; | ||
dev-shell = {type = "derivation";}; | ||
# populated automatically | ||
public.symlinked-env = {type = "derivation";}; | ||
public.dev-shell = {type = "derivation";}; | ||
}; | ||
}; | ||
}; | ||
evaled = lib.evalModules {modules = [module];}; | ||
packages = evaled.config.groups.python-set.public.packages; | ||
env = evaled.config.packages-sets.python-set.public.env; | ||
symlinkedEnv = evaled.config.packge-sets.final-set.public.symlinked-env; | ||
in { | ||
inherit | ||
(packages) | ||
hello | ||
torch | ||
; | ||
}; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
__pypackages__ | ||
.pdm-build | ||
.pdm-python |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
description = "My flake with dream2nix packages"; | ||
|
||
inputs = { | ||
dream2nix.url = "github:nix-community/dream2nix?dir=modules"; | ||
nixpkgs.follows = "dream2nix/nixpkgs"; | ||
}; | ||
|
||
outputs = inputs @ { | ||
self, | ||
dream2nix, | ||
nixpkgs, | ||
... | ||
}: let | ||
system = "x86_64-linux"; | ||
lib = nixpkgs.lib; | ||
module = { | ||
config, | ||
lib, | ||
dream2nix, | ||
... | ||
}: { | ||
imports = [ | ||
dream2nix.modules.dream2nix.WIP-python-pdm | ||
]; | ||
pdm.lockfile = ./pdm.lock; | ||
pdm.pyproject = ./pyproject.toml; | ||
pdm.pythonInterpreter = nixpkgs.legacyPackages.python3; | ||
}; | ||
evaled = lib.evalModules { | ||
modules = [module]; | ||
specialArgs.dream2nix = dream2nix; | ||
specialArgs.packageSets.nixpkgs = nixpkgs.legacyPackages.x86_64-linux; | ||
}; | ||
in { | ||
packages.${system} = evaled.config.groups.default.public.packages; | ||
}; | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
|
||
[project] | ||
name = "my-project" | ||
version = "0.1.0" | ||
description = "" | ||
dependencies = [ | ||
"requests>=2.31.0", | ||
] | ||
requires-python = ">=3.10" | ||
readme = "README.md" | ||
license = {text = "MIT"} | ||
[project.optional-dependencies] | ||
dev = [ | ||
"pi>=0.1.2", | ||
] | ||
|
||
[build-system] | ||
requires = ["pdm-backend"] | ||
build-backend = "pdm.backend" |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
description = "My flake with dream2nix packages"; | ||
|
||
inputs = { | ||
dream2nix.url = "github:nix-community/dream2nix"; | ||
nixpkgs.follows = "dream2nix/nixpkgs"; | ||
}; | ||
|
||
outputs = inputs @ { | ||
self, | ||
dream2nix, | ||
nixpkgs, | ||
... | ||
}: let | ||
system = "x86_64-linux"; | ||
in { | ||
# all packages defined inside ./packages/ | ||
packages.${system}.default = nixpkgs.lib.evalModules { | ||
modules = []; | ||
|
||
projectRoot = ./.; | ||
# can be changed to ".git" or "flake.nix" to get rid of .project-root | ||
projectRootFile = "flake.nix"; | ||
packagesDir = ./packages; | ||
packageSets.nixpkgs = nixpkgs.legacyPackages.${system}; | ||
}; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -118,5 +118,6 @@ | |
] | ||
} | ||
} | ||
} | ||
}, | ||
"invalidationHash": "255d7306e2485fb3c4e4419fc044fed9dade9ea3d0748396036c0e31ea72a03f" | ||
} |
Oops, something went wrong.