Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .chglog/CHANGELOG.tpl.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
{{ range .Unreleased.CommitGroups -}}
### {{ .Title }}
{{ range .Commits -}}
- {{ if .Scope }}**{{ .Scope }}:** {{ end }}{{ .Subject }} ([{{ .Hash.Short }}](https://github.com/PlatformStackPulse/bash-template/commit/{{ .Hash.Long }}))
- {{ if .Scope }}**{{ .Scope }}:** {{ end }}{{ .Subject }} ([{{ .Hash.Short }}](https://github.com/PlatformStackPulse/git-repo-reconciler/commit/{{ .Hash.Long }}))
{{ end }}
{{ end }}
{{ else -}}
Expand All @@ -18,7 +18,7 @@
{{ range .CommitGroups -}}
### {{ .Title }}
{{ range .Commits -}}
- {{ if .Scope }}**{{ .Scope }}:** {{ end }}{{ .Subject }} ([{{ .Hash.Short }}](https://github.com/PlatformStackPulse/bash-template/commit/{{ .Hash.Long }}))
- {{ if .Scope }}**{{ .Scope }}:** {{ end }}{{ .Subject }} ([{{ .Hash.Short }}](https://github.com/PlatformStackPulse/git-repo-reconciler/commit/{{ .Hash.Long }}))
{{ end }}
{{ end }}

Expand Down
2 changes: 1 addition & 1 deletion .chglog/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ style: github
template: CHANGELOG.tpl.md
info:
title: CHANGELOG
repository_url: https://github.com/PlatformStackPulse/bash-template
repository_url: https://github.com/PlatformStackPulse/git-repo-reconciler
options:
commits:
filters:
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "bash-template",
"name": "git-repo-reconciler",
"image": "mcr.microsoft.com/devcontainers/base:ubuntu-24.04",
"features": {
"ghcr.io/devcontainers/features/github-cli:1": {}
Expand Down
2 changes: 1 addition & 1 deletion .github/actions/build/action.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: build
description: GitHub composite action to build bash-template
description: GitHub composite action to build git-repo-reconciler (grr)

runs:
using: composite
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,12 +116,12 @@ jobs:

- name: Verify build artifact
run: |
test -f bin/bash-template
bin/bash-template --version
test -f bin/grr
bin/grr --version

- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: bash-template-binary
path: bin/bash-template
name: grr-binary
path: bin/grr
retention-days: 7
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ jobs:
- name: Build
run: |
chmod +x scripts/build.sh
BINARY_NAME=bash-template scripts/build.sh "${{ steps.version.outputs.version }}"
scripts/build.sh "${{ steps.version.outputs.version }}"

- name: Package release artifacts
run: |
mkdir -p dist
cp bin/bash-template "dist/bash-template-${{ steps.version.outputs.version }}-linux-amd64"
cp bin/grr "dist/grr-${{ steps.version.outputs.version }}-linux-amd64"
cd dist && sha256sum * > SHA256SUMS

- name: Upload artifacts
Expand Down
23 changes: 13 additions & 10 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Contributing to Bash Template
# Contributing to Git Repo Reconciler (GRR)

Thank you for your interest in contributing! This project follows a set of guidelines to ensure code quality and consistency.

Expand All @@ -7,8 +7,8 @@ Thank you for your interest in contributing! This project follows a set of guide
1. **Fork the repository** on GitHub
2. **Clone your fork:**
```bash
git clone https://github.com/PlatformStackPulse/bash-template.git
cd bash-template
git clone https://github.com/PlatformStackPulse/git-repo-reconciler.git
cd git-repo-reconciler
```

3. **Setup development environment:**
Expand Down Expand Up @@ -80,9 +80,9 @@ All commits must follow the [Conventional Commits](https://www.conventionalcommi
**Examples:**
```
feat: add support for parallel processing
feat(cli): add deploy command
fix: resolve timeout handling
fix(logger): fix log rotation
feat(pull): add shallow clone handling
fix: resolve timeout handling on macOS
fix(discovery): fix nameref compatibility with Bash 3.2
docs: update README with examples
chore: upgrade ShellCheck to latest
```
Expand Down Expand Up @@ -146,12 +146,15 @@ lib/ # Shared libraries (sourced, not executed)
├── config.sh # Configuration management
├── errors.sh # Error codes and handling
├── utils.sh # Common utilities
└── version.sh # Version info
├── version.sh # Version info
├── git.sh # Atomic git operations
└── discovery.sh # Repo discovery & skip patterns

src/ # Executable scripts
├── main.sh # Entry point & dispatcher
└── commands/ # Subcommand scripts
└── hello.sh # Example command
├── pull.sh # Bulk-pull reconciliation
└── status.sh # Repository status overview

test/ # BATS tests
├── unit/ # Unit tests (mirrors lib/ and src/)
Expand All @@ -174,9 +177,9 @@ test/ # BATS tests
**Integration Tests:**
```bash
@test "full CLI flow works" {
run bash src/main.sh hello --name "Test"
run bash src/main.sh pull --help
[ "$status" -eq 0 ]
[[ "$output" == *"Hello, Test!"* ]]
[[ "$output" == *"--fetch"* ]]
}
```

Expand Down
5 changes: 3 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ FROM ubuntu:24.04
RUN apt-get update && apt-get install -y --no-install-recommends \
bash \
coreutils \
git \
curl \
jq \
&& rm -rf /var/lib/apt/lists/*
Expand All @@ -35,8 +36,8 @@ WORKDIR /app
RUN groupadd -g 1000 app && \
useradd -u 1000 -g app -s /bin/bash app

COPY --from=base /app/bin/bash-template /usr/local/bin/bash-template
COPY --from=base /app/bin/grr /usr/local/bin/grr

USER app

ENTRYPOINT ["bash-template"]
ENTRYPOINT ["grr"]
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.PHONY: help build run test clean lint fmt security coverage install dev-setup changelog changelog-check

# Variables
BINARY_NAME=bash-template
BINARY_NAME=grr
VERSION?=dev
COMMIT?=$(shell git rev-parse --short HEAD 2>/dev/null || echo "unknown")
BUILD_TIME?=$(shell date -u '+%Y-%m-%d_%H:%M:%S')
Expand All @@ -20,7 +20,7 @@ build: ## Build the application (bundle into bin/)
@echo "Build complete: bin/$(BINARY_NAME)"

run: build ## Build and run the application
@bin/$(BINARY_NAME) hello
@bin/$(BINARY_NAME) --help

test: ## Run all tests (BATS)
@echo "Running tests..."
Expand Down
Loading
Loading