Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,6 @@ jobs:
with:
args: sh -c "chown -R root:root /github/workspace && m . /lintGitMailMap"

lintMarkdown_readme:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@f095bcc56b7c2baf48f3ac70d6d6782f4f553222
- uses: docker://ghcr.io/fluidattacks/makes/amd64:latest
name: /lintMarkdown/readme
with:
args: sh -c "chown -R root:root /github/workspace && m . /lintMarkdown/readme"

lintNix:
runs-on: ubuntu-latest
steps:
Expand Down
11 changes: 0 additions & 11 deletions .github/workflows/prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,17 +104,6 @@ jobs:
env:
CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }}

lintMarkdown_readme:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@f095bcc56b7c2baf48f3ac70d6d6782f4f553222
- uses: docker://ghcr.io/fluidattacks/makes/amd64:latest
name: /lintMarkdown/readme
with:
args: sh -c "chown -R root:root /github/workspace && m . /lintMarkdown/readme"
env:
CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }}

lintNix:
runs-on: ubuntu-latest
steps:
Expand Down
36 changes: 0 additions & 36 deletions .lint-markdown/config.rb

This file was deleted.

1 change: 1 addition & 0 deletions .mailmap
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
Daniel Betancur <[email protected]> Daniel Betancur <[email protected]>
Daniel Salazar <[email protected]> Daniel Salazar <[email protected]>
Daniel Salazar <[email protected]> Daniel Salazar <[email protected]>
Daniel Salazar <[email protected]> Daniel Salazar <[email protected]>
Expand Down
10 changes: 2 additions & 8 deletions api/deploy/main.nix
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
{
inputs,
makeScript,
...
}:
{ inputs, makeScript, ... }:
makeScript {
name = "api-deploy";
replace = {
__argApiCompose__ = ./compose.yaml;
};
replace = { __argApiCompose__ = ./compose.yaml; };
searchPaths = {
bin = [
inputs.nixpkgs.curl
Expand Down
4 changes: 2 additions & 2 deletions api/env/main.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{makePythonEnvironment, ...}:
{ makePythonEnvironment, ... }:
makePythonEnvironment {
pythonProjectDir = ./.;
pythonVersion = "3.11";
pythonVersion = "3.12";
}
245 changes: 165 additions & 80 deletions api/env/poetry.lock

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions api/env/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ readme = "README.md"

[tool.poetry.dependencies]
python = "^3.11"
fastapi = "0.78.0"
uvicorn = "0.18.2"
fastapi = "0.115.4"
uvicorn = "0.32.0"

[build-system]
requires = ["poetry-core"]
Expand Down
14 changes: 3 additions & 11 deletions api/main.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
{
inputs,
makeScript,
outputs,
projectPath,
...
}:
{ inputs, makeScript, outputs, projectPath, ... }:
makeScript {
replace = {
__argApiSrc__ = projectPath "/api/src";
};
replace = { __argApiSrc__ = projectPath "/api/src"; };
name = "api";
searchPaths.source = [outputs."/api/env"];
searchPaths.source = [ outputs."/api/env" ];
entrypoint = ./entrypoint.sh;
}
18 changes: 4 additions & 14 deletions api/makes.nix
Original file line number Diff line number Diff line change
@@ -1,22 +1,12 @@
{
inputs,
outputs,
makePythonPyprojectPackage,
projectPath,
...
}: {
{ inputs, outputs, makePythonPyprojectPackage, projectPath, ... }: {
lintPython = {
modules = {
api = {
searchPaths.source = [outputs."/api/env"];
searchPaths.source = [ outputs."/api/env" ];
src = "/api/src";
};
};
};
lintWithLizard = {
api = ["/api/src"];
};
securePythonWithBandit = {
api.target = "/api/src";
};
lintWithLizard = { api = [ "/api/src" ]; };
securePythonWithBandit = { api.target = "/api/src"; };
}
2 changes: 1 addition & 1 deletion api/src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
app = FastAPI()


class Item(BaseModel): # pylint: disable=too-few-public-methods
class Item(BaseModel):
name: str
price: float
is_offer: Union[bool, None] = None
Expand Down
41 changes: 14 additions & 27 deletions makes.nix
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
{fetchNixpkgs, ...}: {
{ fetchNixpkgs, ... }: {
cache = {
readNixos = true;
extra = {
makes = {
enable = true;
pubKey = "makes.cachix.org-1:zO7UjWLTRR8Vfzkgsu1PESjmb6ymy1e4OE9YfMmCQR4=";
pubKey =
"makes.cachix.org-1:zO7UjWLTRR8Vfzkgsu1PESjmb6ymy1e4OE9YfMmCQR4=";
token = "CACHIX_AUTH_TOKEN";
type = "cachix";
url = "https://makes.cachix.org";
Expand All @@ -14,30 +15,24 @@
};
formatBash = {
enable = true;
targets = ["/"];
targets = [ "/" ];
};
formatMarkdown = {
enable = true;
doctocArgs = ["--title" "# Contents"];
targets = ["/README.md"];
doctocArgs = [ "--title" "# Contents" ];
targets = [ "/README.md" ];
};
formatNix = {
enable = true;
targets = ["/"];
};
formatPython = {
default = {
targets = ["/"];
};
targets = [ "/" ];
};
formatPython = { default = { targets = [ "/" ]; }; };
formatYaml = {
enable = true;
targets = ["/"];
targets = [ "/" ];
};
extendingMakesDirs = ["/"];
imports = [
./api/makes.nix
];
extendingMakesDirs = [ "/" ];
imports = [ ./api/makes.nix ];
inputs = {
nixpkgs = fetchNixpkgs {
rev = "32c00dc37042934c79041116383e27f04ad84710";
Expand All @@ -46,24 +41,16 @@
};
lintBash = {
enable = true;
targets = ["/"];
targets = [ "/" ];
};
lintGitCommitMsg = {
enable = true;
config = "/.lint-git-commit-msg/config.js";
parser = "/.lint-git-commit-msg/parser.js";
};
lintGitMailMap = {
enable = true;
};
lintMarkdown = {
readme = {
config = "/.lint-markdown/config.rb";
targets = ["/"];
};
};
lintGitMailMap = { enable = true; };
lintNix = {
enable = true;
targets = ["/"];
targets = [ "/" ];
};
}
Loading