From 7c3496dea7033c85528c438ec4ea00262f99b679 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rados=C5=82aw=20Kukuczka?= Date: Sun, 30 Mar 2025 13:35:44 +0200 Subject: [PATCH] update readme --- README.md | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 81 insertions(+) diff --git a/README.md b/README.md index e69de29..cc4fca1 100644 --- a/README.md +++ b/README.md @@ -0,0 +1,81 @@ +# ✂️ Generate Short SHA Action + +Quickly generate a short, readable version of your commit SHA for easy referencing and tagging! 🚀 + +--- + +## 🤔 Why Use This Action? + +Long commit SHAs can be cumbersome and hard to read. This action simplifies your workflow by creating a short, 7-character SHA that's perfect for: + +- 🏷️ **Tagging Docker images** +- 📦 **Naming artifacts** +- 📋 **Readable logging and notifications** + +--- + +## ⚙️ How It Works + +Given a commit SHA like: + +``` +258910ce93c0e19f9fba036ceade6407dc16677e +``` + +This action produces a short SHA: + +``` +258910c +``` + +--- + +## 📥 Inputs & 📤 Outputs + +### 📥 Inputs + +No inputs required! It automatically uses the current commit SHA. + +### 📤 Outputs + +| Output | Description | Example | +|---------|-----------------------|-----------| +| `short` | Short 7-char SHA | `258910c` | + +--- + +## 🛠️ Example Usage + +Here's how you can integrate this action into your workflow: + +```yaml +- name: Generate Short SHA ✂️ + id: short-sha + uses: your-org/generate-short-sha@main + +- name: Use Short SHA 📢 + run: | + echo "Short SHA: ${{ steps.short-sha.outputs.short }}" +``` + +--- + +## 🐞 Debugging & Logs + +This action provides simple debug output to help you verify the generated SHA: + +``` +DEBUG: Short SHA = 258910c +``` + +--- + +## 📜 License + +This action is open-source software licensed under the MIT license. + +--- + +Happy coding! 🎉 + +— **Grand** \ No newline at end of file