mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-23 05:05:00 +00:00
code_style: run dotnet format
This commit is contained in:
parent
ed62174942
commit
4610f702b3
29 changed files with 48 additions and 76 deletions
|
@ -52,12 +52,12 @@ namespace SourceGit.Commands
|
|||
var refName = parts[0];
|
||||
if (refName.EndsWith("/HEAD", StringComparison.Ordinal))
|
||||
return;
|
||||
|
||||
|
||||
if (refName.StartsWith(PREFIX_DETACHED, StringComparison.Ordinal))
|
||||
{
|
||||
branch.IsHead = true;
|
||||
}
|
||||
|
||||
|
||||
if (refName.StartsWith(PREFIX_LOCAL, StringComparison.Ordinal))
|
||||
{
|
||||
branch.Name = refName.Substring(PREFIX_LOCAL.Length);
|
||||
|
|
|
@ -57,7 +57,8 @@ namespace SourceGit.Commands
|
|||
if (line.Equals(_endOfBodyToken, StringComparison.Ordinal))
|
||||
{
|
||||
_nextPartIdx = 0;
|
||||
if (!string.IsNullOrEmpty(_current.Message)) _current.Message = _current.Message.Trim();
|
||||
if (!string.IsNullOrEmpty(_current.Message))
|
||||
_current.Message = _current.Message.Trim();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -6,7 +6,8 @@ namespace SourceGit.Commands
|
|||
{
|
||||
public class QuerySingleCommit : Command
|
||||
{
|
||||
public QuerySingleCommit(string repo, string sha) {
|
||||
public QuerySingleCommit(string repo, string sha)
|
||||
{
|
||||
WorkingDirectory = repo;
|
||||
Context = repo;
|
||||
Args = $"show --no-show-signature --decorate=full --pretty=format:%H%n%P%n%D%n%aN±%aE%n%at%n%cN±%cE%n%ct%n%B -s {sha}";
|
||||
|
@ -19,7 +20,7 @@ namespace SourceGit.Commands
|
|||
{
|
||||
var commit = new Models.Commit();
|
||||
var lines = rs.StdOut.Split('\n');
|
||||
if (lines.Length < 8)
|
||||
if (lines.Length < 8)
|
||||
return null;
|
||||
|
||||
commit.SHA = lines[0];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue