poetry init
This commit is contained in:
parent
cc710b3859
commit
e7da4d4b51
2
.gitignore
vendored
2
.gitignore
vendored
@ -10,3 +10,5 @@
|
||||
**/.#*
|
||||
|
||||
.pre-commit-config.yaml
|
||||
|
||||
*.AppImage
|
||||
|
||||
21
flake.nix
21
flake.nix
@ -67,9 +67,30 @@
|
||||
};
|
||||
|
||||
packages = {
|
||||
default = config.packages.k8s-gitlab-borg;
|
||||
|
||||
k8s-gitlab-borg = with pkgs.poetry2nix;
|
||||
mkPoetryApplication {
|
||||
projectDir = cleanPythonSources {src = ./.;};
|
||||
|
||||
nativeBuildInputs = with pkgs; [makeWrapper];
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram $out/bin/k8s-gitlab-borg \
|
||||
${pkgs.lib.escapeShellArgs [
|
||||
"--prefix"
|
||||
"PATH"
|
||||
":"
|
||||
(pkgs.lib.makeBinPath (with pkgs; [borgbackup]))
|
||||
]}
|
||||
'';
|
||||
|
||||
meta.mainProgram = "k8s-gitlab-borg";
|
||||
};
|
||||
};
|
||||
|
||||
overlayAttrs = {
|
||||
inherit (config.packages) k8s-gitlab-borg;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
0
k8s_gitlab_borg/__init__.py
Normal file
0
k8s_gitlab_borg/__init__.py
Normal file
13
k8s_gitlab_borg/__main__.py
Normal file
13
k8s_gitlab_borg/__main__.py
Normal file
@ -0,0 +1,13 @@
|
||||
# SPDX-FileCopyrightText: 2023 Gregor Kleen
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
import os, sys
|
||||
|
||||
|
||||
def main():
|
||||
pass
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sys.exit(main())
|
||||
8
poetry.lock
generated
Normal file
8
poetry.lock
generated
Normal file
@ -0,0 +1,8 @@
|
||||
package = []
|
||||
|
||||
[metadata]
|
||||
lock-version = "1.1"
|
||||
python-versions = "^3.10"
|
||||
content-hash = "53f2eabc9c26446fbcc00d348c47878e118afc2054778c3c803a0a8028af27d9"
|
||||
|
||||
[metadata.files]
|
||||
3
poetry.lock.license
Normal file
3
poetry.lock.license
Normal file
@ -0,0 +1,3 @@
|
||||
SPDX-FileCopyrightText: 2023 Gregor Kleen
|
||||
|
||||
SPDX-License-Identifier: CC0-1.0
|
||||
21
pyproject.toml
Normal file
21
pyproject.toml
Normal file
@ -0,0 +1,21 @@
|
||||
# SPDX-FileCopyrightText: 2023 Gregor Kleen
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
[tool.poetry]
|
||||
name = "k8s-gitlab-borg"
|
||||
version = "0.0.0"
|
||||
description = ""
|
||||
authors = ["Gregor Kleen <gregor@kleen.consulting>"]
|
||||
|
||||
[tool.poetry.dependencies]
|
||||
python = "^3.10"
|
||||
|
||||
|
||||
[tool.poetry.scripts]
|
||||
k8s-gitlab-borg = "k8s_gitlab_borg.__main__:main"
|
||||
|
||||
|
||||
[build-system]
|
||||
requires = ["poetry-core"]
|
||||
build-backend = "poetry.core.masonry.api"
|
||||
Loading…
Reference in New Issue
Block a user