mirror of
https://gitlab.com/rensa-nix/devshell.git
synced 2026-02-02 07:15:09 +01:00
chore: add devtools
This commit is contained in:
parent
7d0c4bc78d
commit
a9d35d750f
11 changed files with 146 additions and 28 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
# Generated by soonix, DO NOT EDIT
|
# Generated by soonix, DO NOT EDIT
|
||||||
include:
|
include:
|
||||||
- component: gitlab.com/TECHNOFAB/nix-gitlab-ci/nix-gitlab-ci@3.0.0-alpha.2
|
- component: gitlab.com/TECHNOFAB/nix-gitlab-ci/nix-gitlab-ci@3.1.2
|
||||||
inputs:
|
inputs:
|
||||||
version: 3.0.0-alpha.2
|
version: 3.1.2
|
||||||
|
|
|
||||||
26
.gitlab/renovate.json5
Normal file
26
.gitlab/renovate.json5
Normal file
|
|
@ -0,0 +1,26 @@
|
||||||
|
|
||||||
|
{
|
||||||
|
"extends": [
|
||||||
|
"config:recommended"
|
||||||
|
],
|
||||||
|
"gitlabci": {
|
||||||
|
"enabled": false
|
||||||
|
},
|
||||||
|
"lockFileMaintenance": {
|
||||||
|
"branchTopic": "lock-file-maintenance-{{packageFile}}",
|
||||||
|
"commitMessageExtra": "({{packageFile}})",
|
||||||
|
"enabled": true,
|
||||||
|
"extends": [
|
||||||
|
"schedule:monthly"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"nix": {
|
||||||
|
"enabled": true
|
||||||
|
},
|
||||||
|
"postUpgradeTasks": {
|
||||||
|
"commands": [
|
||||||
|
"nix-portable nix run .#soonix:update"
|
||||||
|
],
|
||||||
|
"executionMode": "branch"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -6,4 +6,3 @@ DevShell is used in these projects, feel free to take inspiration from them:
|
||||||
- [soonix](https://gitlab.com/TECHNOFAB/soonix)
|
- [soonix](https://gitlab.com/TECHNOFAB/soonix)
|
||||||
- [rensa-core](https://gitlab.com/rensa-nix/core)
|
- [rensa-core](https://gitlab.com/rensa-nix/core)
|
||||||
- [rensa-devtools](https://gitlab.com/rensa-nix/devtools)
|
- [rensa-devtools](https://gitlab.com/rensa-nix/devtools)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -12,4 +12,3 @@ Additional functionality can be added with modules, like [Rensa DevTools](https:
|
||||||
- **fast**: due to the NixOS module system it's a bit slower than `pkgs.mkShell`, but only about 10% (still in the tens of milliseconds range)
|
- **fast**: due to the NixOS module system it's a bit slower than `pkgs.mkShell`, but only about 10% (still in the tens of milliseconds range)
|
||||||
- **minimal**: only contains the bare minimum, the rest should be added with imported modules
|
- **minimal**: only contains the bare minimum, the rest should be added with imported modules
|
||||||
- **straight forward**: no toml (like numtide/devshell), no abstractions over Nix (like devenv), just a straight forward Nix lib
|
- **straight forward**: no toml (like numtide/devshell), no abstractions over Nix (like devenv), just a straight forward Nix lib
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2,4 +2,3 @@
|
||||||
|
|
||||||
- [soonix](https://soonix.projects.tf/usage/#with-devshell)
|
- [soonix](https://soonix.projects.tf/usage/#with-devshell)
|
||||||
- [rensa devtools](https://devtools.rensa.projects.tf)
|
- [rensa devtools](https://devtools.rensa.projects.tf)
|
||||||
|
|
||||||
|
|
|
||||||
13
flake.lock
generated
13
flake.lock
generated
|
|
@ -2,11 +2,11 @@
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1754498491,
|
"lastModified": 1766902085,
|
||||||
"narHash": "sha256-erbiH2agUTD0Z30xcVSFcDHzkRvkRXOQ3lb887bcVrs=",
|
"narHash": "sha256-coBu0ONtFzlwwVBzmjacUQwj3G+lybcZ1oeNSQkgC0M=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "c2ae88e026f9525daf89587f3cbee584b92b6134",
|
"rev": "c0b0e0fddf73fd517c3471e546c0df87a42d53f4",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
@ -37,16 +37,17 @@
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"dir": "lib",
|
"dir": "lib",
|
||||||
"lastModified": 1756370106,
|
"lastModified": 1766497301,
|
||||||
"narHash": "sha256-l84ojcHuQWBwn4BRxQsMMfQpcq/Az/sHh/hSqFgVtyg=",
|
"narHash": "sha256-W7WeOXMUZROMtbU1qQNWy/yai+k8gG09YACFQ7ImpsQ=",
|
||||||
"owner": "rensa-nix",
|
"owner": "rensa-nix",
|
||||||
"repo": "core",
|
"repo": "core",
|
||||||
"rev": "9c1a29fa9ba7cbbb78b9e47eb8afbcd29303a3b4",
|
"rev": "e08c48b5db1052bfb8b8dad764e05decc1af893e",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"dir": "lib",
|
"dir": "lib",
|
||||||
"owner": "rensa-nix",
|
"owner": "rensa-nix",
|
||||||
|
"ref": "v0.1.1",
|
||||||
"repo": "core",
|
"repo": "core",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||||
ren.url = "gitlab:rensa-nix/core?dir=lib";
|
ren.url = "gitlab:rensa-nix/core/v0.1.1?dir=lib";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {
|
outputs = {
|
||||||
|
|
@ -24,6 +24,7 @@
|
||||||
(simple "benchmark")
|
(simple "benchmark")
|
||||||
(simple "docs")
|
(simple "docs")
|
||||||
(simple "ci")
|
(simple "ci")
|
||||||
|
(simple "soonix")
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
|
|
@ -32,6 +33,7 @@
|
||||||
["repo" "benchmark"]
|
["repo" "benchmark"]
|
||||||
["repo" "docs"]
|
["repo" "docs"]
|
||||||
["repo" "ci" "packages"]
|
["repo" "ci" "packages"]
|
||||||
|
["repo" "soonix" "packages"]
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,22 +3,57 @@
|
||||||
cell,
|
cell,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
inherit (inputs) pkgs devshell treefmt soonix;
|
inherit (inputs) pkgs devshell treefmt devtools-lib;
|
||||||
inherit (cell) ci;
|
inherit (cell) soonix;
|
||||||
|
treefmtWrapper = treefmt.mkWrapper pkgs {
|
||||||
|
programs = {
|
||||||
|
alejandra.enable = true;
|
||||||
|
deadnix.enable = true;
|
||||||
|
mdformat.enable = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
in {
|
in {
|
||||||
default = devshell.mkShell {
|
default = devshell.mkShell {
|
||||||
imports = [soonix.devshellModule];
|
imports = [soonix.devshellModule devtools-lib.devshellModule];
|
||||||
packages = [
|
packages = [
|
||||||
pkgs.nil
|
pkgs.nil
|
||||||
(treefmt.mkWrapper pkgs {
|
treefmtWrapper
|
||||||
programs = {
|
|
||||||
alejandra.enable = true;
|
|
||||||
deadnix.enable = true;
|
|
||||||
mdformat.enable = true;
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
];
|
||||||
soonix.hooks.ci = ci.soonix;
|
lefthook.config = {
|
||||||
|
"pre-commit" = {
|
||||||
|
parallel = true;
|
||||||
|
jobs = [
|
||||||
|
{
|
||||||
|
name = "treefmt";
|
||||||
|
stage_fixed = true;
|
||||||
|
run = "${treefmtWrapper}/bin/treefmt";
|
||||||
|
env.TERM = "dumb";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
name = "soonix";
|
||||||
|
stage_fixed = true;
|
||||||
|
run = "${soonix.packages."soonix:update"}/bin/soonix:update";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
cocogitto.config = {
|
||||||
|
tag_prefix = "v";
|
||||||
|
ignore_merge_commits = true;
|
||||||
|
changelog = {
|
||||||
|
authors = [
|
||||||
|
{
|
||||||
|
username = "TECHNOFAB";
|
||||||
|
signature = "technofab";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
path = "CHANGELOG.md";
|
||||||
|
template = "remote";
|
||||||
|
remote = "gitlab.com";
|
||||||
|
repository = "devshell";
|
||||||
|
owner = "rensa-nix";
|
||||||
|
};
|
||||||
|
};
|
||||||
meta = {
|
meta = {
|
||||||
enableMenu = true;
|
enableMenu = true;
|
||||||
showMenu = "always";
|
showMenu = "always";
|
||||||
|
|
|
||||||
26
nix/repo/flake.lock
generated
26
nix/repo/flake.lock
generated
|
|
@ -1,19 +1,36 @@
|
||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
|
"devtools-lib": {
|
||||||
|
"locked": {
|
||||||
|
"dir": "lib",
|
||||||
|
"lastModified": 1767214272,
|
||||||
|
"narHash": "sha256-gvW7flZ60xdv3Z3Ksec5jcRjW2sqRHsGoJdwsNWQVPk=",
|
||||||
|
"owner": "rensa-nix",
|
||||||
|
"repo": "devtools",
|
||||||
|
"rev": "f40e59c32c48cdbf4cbc621c2f0f11e7bb80dbd3",
|
||||||
|
"type": "gitlab"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"dir": "lib",
|
||||||
|
"owner": "rensa-nix",
|
||||||
|
"repo": "devtools",
|
||||||
|
"type": "gitlab"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nix-gitlab-ci-lib": {
|
"nix-gitlab-ci-lib": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"dir": "lib",
|
"dir": "lib",
|
||||||
"lastModified": 1756974596,
|
"lastModified": 1765444672,
|
||||||
"narHash": "sha256-KxQj76sUqvPNtrqzNWMZeOWqTitc0aFCYj7UZzToiEA=",
|
"narHash": "sha256-B0cMjRs9P50ym9Le0VUcRN69Yy6tbV13MXq81tTTEus=",
|
||||||
"owner": "TECHNOFAB",
|
"owner": "TECHNOFAB",
|
||||||
"repo": "nix-gitlab-ci",
|
"repo": "nix-gitlab-ci",
|
||||||
"rev": "00cf5b83c6c46698fba12a54b9cc15c6d4e5a4dd",
|
"rev": "8f88a53b5479773cd626420362631bc1da99e677",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"dir": "lib",
|
"dir": "lib",
|
||||||
"owner": "TECHNOFAB",
|
"owner": "TECHNOFAB",
|
||||||
"ref": "3.0.0-alpha.2",
|
"ref": "3.1.2",
|
||||||
"repo": "nix-gitlab-ci",
|
"repo": "nix-gitlab-ci",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
}
|
}
|
||||||
|
|
@ -54,6 +71,7 @@
|
||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
|
"devtools-lib": "devtools-lib",
|
||||||
"nix-gitlab-ci-lib": "nix-gitlab-ci-lib",
|
"nix-gitlab-ci-lib": "nix-gitlab-ci-lib",
|
||||||
"nixmkdocs": "nixmkdocs",
|
"nixmkdocs": "nixmkdocs",
|
||||||
"nixtest-lib": "nixtest-lib",
|
"nixtest-lib": "nixtest-lib",
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,8 @@
|
||||||
nixtest-lib.url = "gitlab:TECHNOFAB/nixtest?dir=lib";
|
nixtest-lib.url = "gitlab:TECHNOFAB/nixtest?dir=lib";
|
||||||
nixmkdocs.url = "gitlab:TECHNOFAB/nixmkdocs?dir=lib";
|
nixmkdocs.url = "gitlab:TECHNOFAB/nixmkdocs?dir=lib";
|
||||||
soonix-lib.url = "gitlab:TECHNOFAB/soonix?dir=lib";
|
soonix-lib.url = "gitlab:TECHNOFAB/soonix?dir=lib";
|
||||||
nix-gitlab-ci-lib.url = "gitlab:TECHNOFAB/nix-gitlab-ci/3.0.0-alpha.2?dir=lib";
|
nix-gitlab-ci-lib.url = "gitlab:TECHNOFAB/nix-gitlab-ci/3.1.2?dir=lib";
|
||||||
|
devtools-lib.url = "gitlab:rensa-nix/devtools/v0.1.0?dir=lib";
|
||||||
treefmt-nix = {
|
treefmt-nix = {
|
||||||
url = "github:numtide/treefmt-nix";
|
url = "github:numtide/treefmt-nix";
|
||||||
flake = false;
|
flake = false;
|
||||||
|
|
|
||||||
38
nix/repo/soonix.nix
Normal file
38
nix/repo/soonix.nix
Normal file
|
|
@ -0,0 +1,38 @@
|
||||||
|
{
|
||||||
|
inputs,
|
||||||
|
cell,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
inherit (inputs) soonix;
|
||||||
|
inherit (cell) ci;
|
||||||
|
in
|
||||||
|
(soonix.make {
|
||||||
|
hooks = {
|
||||||
|
ci = ci.soonix;
|
||||||
|
renovate = {
|
||||||
|
output = ".gitlab/renovate.json5";
|
||||||
|
data = {
|
||||||
|
extends = ["config:recommended"];
|
||||||
|
postUpgradeTasks = {
|
||||||
|
commands = [
|
||||||
|
"nix-portable nix run .#soonix:update"
|
||||||
|
];
|
||||||
|
executionMode = "branch";
|
||||||
|
};
|
||||||
|
lockFileMaintenance = {
|
||||||
|
enabled = true;
|
||||||
|
extends = ["schedule:monthly"];
|
||||||
|
branchTopic = "lock-file-maintenance-{{packageFile}}";
|
||||||
|
commitMessageExtra = "({{packageFile}})";
|
||||||
|
};
|
||||||
|
nix.enabled = true;
|
||||||
|
gitlabci.enabled = false;
|
||||||
|
};
|
||||||
|
hook = {
|
||||||
|
mode = "copy";
|
||||||
|
gitignore = false;
|
||||||
|
};
|
||||||
|
opts.format = "json";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}).config
|
||||||
Loading…
Add table
Add a link
Reference in a new issue