Přeskočit na obsah

Tato stránka byla automaticky přeložena z angličtiny, jediného jazyka, ve kterém se tento web píše. Číst originál.

commit.history

Každý commit v rozsahu gitu proti politice commitů, v jednom průchodu: kolik jich bylo přečteno, kolik git složil a jsou vyňaty, kolik nese chybu a každý commit, který má nález, s tím, co to je. Co čte kontrola, aby odmítla nový dluh, a co odpovídá na `je historie této větve čistá?` bez procesu na commit.

Každý commit v rozsahu gitu proti politice commitů, v jednom průchodu: kolik jich bylo přečteno, kolik git složil a jsou vyňaty, kolik nese chybu a každý commit, který má nález, s tím, co to je. Co čte kontrola, aby odmítla nový dluh, a co odpovídá na `je historie této větve čistá?` bez procesu na commit.

Zpřístupnění

Kde je tato jedna definice dosažitelná. Absence je explicitní: povrch, který není uveden, ji nenese.

povrchjako
MCPnástroj majordomus_commit_history
HTTPGET /api/v1/commit/history operationId commit.history
příkazová řádkamajordomus commit history

Schémata

Kanonický vstup a výstup z typů Rustu; schéma nástroje MCP a parametry a odpovědi OpenAPI se odvozují z nich.

vstup · HistoryInput

Který rozsah historie posuzovat.

use majordomus_cli::capability::builtin::commit::HistoryInput;
let h: HistoryInput = serde_json::from_str("{}").expect("an empty input");
assert_eq!(h.range, "HEAD", "the whole history reachable from here");
vlastnosttyppovinnépopis
rozsah string ne Cokoli, co přijímá git log: origin/master..HEAD, v0.6.0.., holé HEAD. Výchozí je HEAD, tedy celá historie dosažitelná odsud. výchozí "HEAD"
JSON Schema
{
  "additionalProperties": false,
  "description": "Which range of history to judge.\n```\nuse majordomus_cli::capability::builtin::commit::HistoryInput;\nlet h: HistoryInput = serde_json::from_str(\"{}\").expect(\"an empty input\");\nassert_eq!(h.range, \"HEAD\", \"the whole history reachable from here\");\n```",
  "properties": {
    "range": {
      "default": "HEAD",
      "description": "Anything `git log` accepts: `origin/master..HEAD`, `v0.6.0..`, a bare `HEAD`.\nDefault `HEAD`, which is the whole history reachable from here.",
      "type": "string"
    }
  },
  "title": "HistoryInput",
  "type": "object"
}

výstup · HistoryReport

Rozsah historie, posouzený. Rozsah historie, posouzený jedním průchodem.

use majordomus_cli::commit::verdict::HistoryReport;
let r = HistoryReport {
    range: "HEAD".into(),
    total: 1755,
    exempt: 561,
    failing: 54,
    commits: Vec::new(),
};
// a commit with nothing to say is counted and not listed: a report of a thousand
// passing commits is a report nobody reads
assert!(r.commits.is_empty());
assert_eq!(r.total - r.exempt, 1194);
vlastnosttyppovinnépopis
commity array ano Každý commit, který nese zjištění, od nejnovějšího. Commit, který nemá co říct, se započítá a nevypíše: zpráva, která by vypsala tisíc prošlých commitů, by byla zprávou, kterou nikdo nečte.
exempt integer ano Kolik jich bylo vyňato, protože jejich předmět složil git.
selhávající integer ano Kolik jich nese zjištění závažnosti error.
rozsah string ano Rozsah, jak byl požadován.
celkem integer ano Kolik commitů bylo přečteno.
JSON Schema
{
  "$defs": {
    "CommitExemption": {
      "description": "Why a commit was not judged.\n```\nuse majordomus_cli::commit::{judge, CommitExemption, CommitPolicy, CommitSubject};\nlet v = judge(&CommitSubject::of(\"Merge pull request #1 from a/b\"), &CommitPolicy::default());\nassert_eq!(v.exempt, Some(CommitExemption::GitAuthored));\n```",
      "oneOf": [
        {
          "const": "git_authored",
          "description": "git composed the subject: a merge, a revert, a fixup.",
          "type": "string"
        }
      ]
    },
    "Diagnostic": {
      "description": "One finding about the declarative state, named by a stable code, tied to a path where\nthere is one, and carrying the command that reproduces it where there is one.",
      "properties": {
        "code": {
          "description": "A stable machine-readable code, e.g. `unknown_key`, `duplicate_identity`.",
          "type": "string"
        },
        "message": {
          "description": "What is wrong, for a person; the code is for a program.",
          "type": "string"
        },
        "path": {
          "description": "Repository-relative path of the file concerned, when there is one.",
          "type": [
            "string",
            "null"
          ]
        },
        "severity": {
          "$ref": "#/$defs/Severity",
          "description": "How bad."
        }
      },
      "required": [
        "severity",
        "code",
        "message"
      ],
      "type": "object"
    },
    "JudgedCommit": {
      "description": "One commit of the history, judged.\n```\nuse majordomus_cli::commit::verdict::JudgedCommit;\n// what a history report lists: only the commits that have something to say\nlet row = JudgedCommit {\n    commit: \"a1b2c3d4e\".into(),\n    subject: \"update stuff\".into(),\n    passed: false,\n    exempt: None,\n    findings: Vec::new(),\n};\nassert!(!row.passed);\n```",
      "properties": {
        "commit": {
          "description": "The commit name, as git gave it.",
          "type": "string"
        },
        "exempt": {
          "anyOf": [
            {
              "$ref": "#/$defs/CommitExemption"
            },
            {
              "type": "null"
            }
          ],
          "description": "Why it was not judged, when it was not."
        },
        "findings": {
          "description": "Every finding.",
          "items": {
            "$ref": "#/$defs/Diagnostic"
          },
          "type": "array"
        },
        "passed": {
          "description": "Whether it passed.",
          "type": "boolean"
        },
        "subject": {
          "description": "Its subject line.",
          "type": "string"
        }
      },
      "required": [
        "commit",
        "subject",
        "passed",
        "findings"
      ],
      "type": "object"
    },
    "Severity": {
      "description": "How bad a diagnostic is. `Error` excludes the file it concerns from the index and puts\nthe index into the degraded state; `Warning` and `Info` do neither.",
      "oneOf": [
        {
          "const": "info",
          "description": "Worth knowing; changes nothing.",
          "type": "string"
        },
        {
          "const": "warning",
          "description": "Something to look at; the object is still served.",
          "type": "string"
        },
        {
          "const": "error",
          "description": "The file is excluded and the index is degraded.",
          "type": "string"
        }
      ]
    }
  },
  "description": "A range of history, judged.\nA range of history, judged in one pass.\n\n```\nuse majordomus_cli::commit::verdict::HistoryReport;\nlet r = HistoryReport {\n    range: \"HEAD\".into(),\n    total: 1755,\n    exempt: 561,\n    failing: 54,\n    commits: Vec::new(),\n};\n// a commit with nothing to say is counted and not listed: a report of a thousand\n// passing commits is a report nobody reads\nassert!(r.commits.is_empty());\nassert_eq!(r.total - r.exempt, 1194);\n```",
  "properties": {
    "commits": {
      "description": "Every commit that carries a finding, newest first. A commit with nothing to say is\ncounted and not listed: a report that printed a thousand passing commits would be a\nreport nobody reads.",
      "items": {
        "$ref": "#/$defs/JudgedCommit"
      },
      "type": "array"
    },
    "exempt": {
      "description": "How many were exempt because git composed their subject.",
      "format": "uint",
      "minimum": 0,
      "type": "integer"
    },
    "failing": {
      "description": "How many carry a finding of error severity.",
      "format": "uint",
      "minimum": 0,
      "type": "integer"
    },
    "range": {
      "description": "The range as asked for.",
      "type": "string"
    },
    "total": {
      "description": "How many commits were read.",
      "format": "uint",
      "minimum": 0,
      "type": "integer"
    }
  },
  "required": [
    "range",
    "total",
    "exempt",
    "failing",
    "commits"
  ],
  "title": "HistoryReport",
  "type": "object"
}

Politiky

benchmark
povinné — cíl na každém transportu, který expozice deklaruje; případy jsou ty ze vstupního typu
cache
vypnuto — každé volání spustí handler

Cíle benchmarku

Odvozeno z registru pro tento repozitář: jeden požadavek na transport a případy, které poskytuje typ vstupu. Celá matice je na stránce měření výkonu.

transportstatepřípadytargets
directpokryto1whole-history
mcppokryto1whole-history
httppokryto1whole-history

Prohledává názvy a popisy všech stránek, které tento web publikuje.