Feature: Add signature parsing to raw() for --show-signature - #HSFDPMUW - #1185
Open
AhmedouNdeddou wants to merge 11 commits into
Open
Feature: Add signature parsing to raw() for --show-signature - #HSFDPMUW#1185AhmedouNdeddou wants to merge 11 commits into
AhmedouNdeddou wants to merge 11 commits into
Conversation
### Inhalt Dieser Pull Request ergänzt einen Unit-Test, der die Funktionen `.add()` und `.commit()` von `simple-git` testet. ### Details - Erstellt temporär ein Repository in einem neuen Ordner - Legt eine Datei `test.txt` an - Führt `.add()` und `.commit()` durch - Überprüft per `.log()`, ob der Commit erfolgreich war ### Erwartung - Git-Log enthält mindestens einen Commit - Letzter Commit hat die Nachricht: `Add test.txt` ### Warum ist das wichtig? - Testet zwei der wichtigsten Basisfunktionen von `simple-git` - Stellt sicher, dass das `add + commit`-Verhalten korrekt funktioniert - Erhöht die Testabdeckung und stärkt das Vertrauen in die API ### Kontext Dieser Beitrag erfolgt im Rahmen des Hochschulprojekts **#HSFDPMUW** – Modul: Programmiermethoden & Werkzeuge.
Test: add and commit a file using simple-git #HSFDPMUW
### Inhalt Dieser Pull Request enthält einen Unit-Test für die Methode `.checkoutLocalBranch()` von `simple-git`. ### Details - Erstellt ein temporäres Git-Repository - Macht einen leeren Initial-Commit (`--allow-empty`) - Erstellt und wechselt zu einem neuen Branch `feature-branch` mit `.checkoutLocalBranch()` - Prüft, ob der aktuelle Branch korrekt gesetzt wurde ### Erwartung - Aktueller Branch ist `feature-branch` ### Warum ist das nützlich? - Testet typisches Branch-Management-Verhalten - Verifiziert, dass `.checkoutLocalBranch()` wie dokumentiert funktioniert - Trägt zur Testabdeckung und zur Robustheit der API bei ### Kontext Dieser Beitrag erfolgt im Rahmen des Hochschulprojekts **#HSFDPMUW** – Modul: Programmiermethoden & Werkzeuge.
Test: checkoutLocalBranch should switch to new branch #HSFDPMUW
### Inhalt Dieser Pull Request fügt einen Unit-Test für die Methode `.log()` von `simple-git` hinzu. ### Details - Erstellt ein temporäres Git-Repository - Fügt zwei Dateien nacheinander hinzu (`file1.txt`, `file2.txt`) - Führt jeweils einen Commit durch - Ruft `.log()` auf und überprüft die Historie ### Erwartung - Git-Log gibt zwei Commits zurück - Beide Commit-Messages sind enthalten (`first commit`, `second commit`) ### Warum ist das nützlich? - Testet ein zentrales Feature: die Historie der Commits - Verifiziert das Verhalten von `.log()` mit mehreren Einträgen - Unterstützt die langfristige Stabilität der API ### Kontext Dieser Beitrag erfolgt im Rahmen des Hochschulprojekts **#HSFDPMUW** – Modul: Programmiermethoden & Werkzeuge.
Test: log should return multiple commits from history #HSFDPMUW
Adds native parsing of Git trailers in commit objects: - Adds 'trailers' property to CommitResult interface - Adds parseTrailers function in parse-commit.ts - Parses trailers from commit message body This allows users to access structured trailer data like: - Signed-off-by - Reviewed-by - Custom trailers Closes steveukx#1046
Uses Node.js process.env as base for environment variables in git processes. - Adds env option to SimpleGitOptions - Merges process.env with custom env variables in GitExecutor - Passes env through Git factory and Git class constructor - Allows overriding specific environment variables Closes steveukx#1017
Prevents zombie processes in Docker environments by: - Using detached: true in spawn options for remote commands - Calling child.unref() to detach from parent process - Only affects remote commands (fetch, pull, push, clone, remote) Closes steveukx#1062
Adds state information to StatusResult: - ebasing: true when a rebase is in progress - cherryPicking: true when a cherry-pick is in progress - Parses from git status output Closes steveukx#1029
Adds signature information parsing when using git.raw(['--show-signature', ...]): - Added SignatureInfo interface - Added RawResult interface - Parses GPG signature status (GOOD/BAD/ERROR/NONE) - Extracts signer name, email, key ID and timestamp Closes steveukx#990
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This change adds signature information parsing when using
git.raw(['--show-signature', ...]).What was done
SignatureInfointerfaceRawResultinterfaceExample