Greasy Fork is available in English.

GitHub コミットメッセージ HTML ビュー

このスクリプトは、GitHub 上のコミットメッセージを HTML ビューに変換し、コミットの詳細をより明確に表示します。コミットメッセージのリスト、コミットヘッダー、最新のコミット情報を自動的に HTML 形式に変換し、視覚的な魅力とユーザー体験を向上させます。

2024/08/30のページです。最新版はこちら。

作者のサイトでサポートを受ける。または、このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください。
作者
人民的勤务员
評価
0 0 0
バージョン
1.0.0.01
作成日
2024/08/30
更新日
2024/08/30
大きさ
16.9KB
ライセンス
MIT
対象サイト

GitHub CommitMessage Html View

Description

GitHub CommitMessage Html View is a user script designed to convert commit messages on GitHub into HTML views, providing clearer commit details. This script automatically transforms commit message lists, commit headers, and the latest commit information into HTML format to enhance visual appeal and user experience, and can be used in conjunction with Git.

Features

  • Commit Message List Transformation: Converts commit messages in the commit list to HTML view.
  • Header Information Display: Shows detailed information about commit headers and the latest commit.
  • Enhanced Visuals: Improves the visibility and user experience of commit information.

Using PowerShell to Upload to a Remote Repository

Clickqinwuyuan.ps1 to download the PowerShell script.

param ( [string]$qinwuyuan_messageFilePath ) $qinwuyuan_scriptPath = $PSScriptRoot $qinwuyuan_rootDrive1 = [System.IO.Path]::GetPathRoot($qinwuyuan_scriptPath).TrimEnd('\') if (-not $qinwuyuan_messageFilePath) { $qinwuyuan_messageFilePath = "$qinwuyuan_rootDrive1\path\to\change\commit.txt" } $qinwuyuan_oldCommitFilePath = "$qinwuyuan_scriptPath\oldcommit.txt" if (-not (Test-Path $qinwuyuan_messageFilePath)) { exit 1 } if (-not (Test-Path .git)) { exit 1 } $qinwuyuan_newCommitMessage = Get-Content $qinwuyuan_messageFilePath -Raw $qinwuyuan_oldCommitMessage = if (Test-Path $qinwuyuan_oldCommitFilePath) { Get-Content $qinwuyuan_oldCommitFilePath -Raw } else { "" } if ($qinwuyuan_newCommitMessage -eq $qinwuyuan_oldCommitMessage) { $qinwuyuan_currentDateTime = Get-Date -Format "yyyy/M/d HH:mm:ss" $qinwuyuan_commitMessage = @" <b><img src="https://avatars.githubusercontent.com/u/96548841?v=4&size=32"> <a href="https://github.com/ChinaGodMan"> <ruby>人民的勤务员<rt>Github:ChinaGodMan</rt></ruby> </a> <span>(UTC+8) $qinwuyuan_currentDateTime </span></b> "@ } else { $qinwuyuan_currentDateTime = Get-Date -Format "yyyy/M/d HH:mm:ss" $qinwuyuan_commitMessage = $qinwuyuan_newCommitMessage -replace '\$qinwuyuan_currentDateTime', $qinwuyuan_currentDateTime } $qinwuyuan_currentBranch = git rev-parse --abbrev-ref HEAD if ($LASTEXITCODE -ne 0) { exit 1 } git add . git commit -m $qinwuyuan_commitMessage if ($LASTEXITCODE -ne 0) { exit 1 } git push origin $qinwuyuan_currentBranch --force if ($LASTEXITCODE -ne 0) { exit 1 } Copy-Item -Path $qinwuyuan_messageFilePath -Destination $qinwuyuan_oldCommitFilePath -Force

Support

License

This script is licensed under the MIT License.

After: 1.png Before: 2.png