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
17 changes: 9 additions & 8 deletions .agents/skills/ci-act-run/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ compatibility: opencode
- Supports two build paths selectable at runtime:
- **pull_request** — simulates a PR build: `act pull_request` sets `CI_IS_PR=true` → script runs `perform_verify()`.
- **develop snapshot** — simulates a push to the develop branch: `act push` with `GITHUB_REF_NAME=develop`, `CI_IS_PR=false`, `CI_BRANCH=develop` → script runs `perform_snapshot_release()`.
- `DRY_RUN` is configurable (default `true`). With `DRY_RUN=true`, no actual deploys or pushes are made — safe for local testing.
- `DRY_RUN` is configurable via the GitHub repository variable `DRY_RUN` (default `true`). With `DRY_RUN=true`, no actual deploys or pushes are made — safe for local testing.
- The archive step is automatically skipped because the workflow guards it with `!env.ACT`.
- Uses the Docker image already configured in `.actrc`: `catthehacker/ubuntu:full-latest`.

Expand Down Expand Up @@ -118,14 +118,15 @@ If the user selects anything other than `all`, append `--matrix java:<version>`

Run the appropriate command from the repo root based on the choices made in steps 3, 4, and 5.

> **REMINDER:** When `DRY_RUN=true`, do NOT include `--secret GITHUB_TOKEN=<anything>` — it causes the run to fail.
> **REMINDER:** Use `--var DRY_RUN=true/false` instead of `--env DRY_RUN=true/false`. The workflow reads DRY_RUN from the GitHub repository variable (`${{ vars.DRY_RUN }}`) via the `--var` flag in `act`. `--env` is overridden by the workflow's `env` block and has no effect.
> When `DRY_RUN=true`, do NOT include `--secret GITHUB_TOKEN=<anything>` — it causes the run to fail.
> When `DRY_RUN=false`, secrets are read from `.env` via `--secret-file .env`. Ensure the file exists at the project root with all required values before running.

#### pull_request + DRY_RUN=true (default, safe)
```bash
act pull_request \
-W .github/workflows/build-and-deploy.yaml \
--env DRY_RUN=true \
--var DRY_RUN=true \
--secret ENCRYPTION_PASSWORD=dummy \
--secret CI_DEPLOY_USERNAME=dummy \
--secret CI_DEPLOY_PASSWORD=dummy \
Expand All @@ -137,7 +138,7 @@ act pull_request \
act pull_request \
-W .github/workflows/build-and-deploy.yaml \
--matrix java:17 \
--env DRY_RUN=true \
--var DRY_RUN=true \
--secret ENCRYPTION_PASSWORD=dummy \
--secret CI_DEPLOY_USERNAME=dummy \
--secret CI_DEPLOY_PASSWORD=dummy \
Expand All @@ -148,7 +149,7 @@ act pull_request \
```bash
act pull_request \
-W .github/workflows/build-and-deploy.yaml \
--env DRY_RUN=false \
--var DRY_RUN=false \
--secret GITHUB_TOKEN=<real_token> \
--secret ENCRYPTION_PASSWORD=<real_password> \
--secret CI_DEPLOY_USERNAME=<real_username> \
Expand All @@ -160,7 +161,7 @@ act pull_request \
```bash
act push \
-W .github/workflows/build-and-deploy.yaml \
--env DRY_RUN=true \
--var DRY_RUN=true \
--env GITHUB_REF_NAME=develop \
--secret ENCRYPTION_PASSWORD=dummy \
--secret CI_DEPLOY_USERNAME=dummy \
Expand All @@ -173,7 +174,7 @@ act push \
act push \
-W .github/workflows/build-and-deploy.yaml \
--matrix java:17 \
--env DRY_RUN=true \
--var DRY_RUN=true \
--env GITHUB_REF_NAME=develop \
--secret ENCRYPTION_PASSWORD=dummy \
--secret CI_DEPLOY_USERNAME=dummy \
Expand All @@ -187,7 +188,7 @@ Uses `--secret-file .env`. For snapshot builds, only `CI_DEPLOY_USERNAME`, `CI_D
act push \
-W .github/workflows/build-and-deploy.yaml \
--matrix java:8 \
--env DRY_RUN=false \
--var DRY_RUN=false \
--env GITHUB_REF_NAME=develop \
--secret-file .env
```
Expand Down
44 changes: 0 additions & 44 deletions .clinerules/workflows/ci-build-dry-run.md

This file was deleted.

2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
*.jsp text
*.jspf text
*.properties text
*.sh text
*.sh text eol=lf # act on Windows won't be able to execute with crlf line endings
*.sql text
*.svg text
*.tld text
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-and-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
# SNAPSHOT_BRANCH: develop
# RELEASE_BRANCH: master
# RELEASE_JDK: openjdk8
# DRY_RUN: "true" # enable to skip deploy/push in this workflow
DRY_RUN: ${{ vars.DRY_RUN || 'true' }} # default: skip deploy/push in this workflow

# Secrets
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -66,7 +66,7 @@ jobs:
echo "CI_DEPLOY_PASSWORD=${CI_DEPLOY_PASSWORD}"
echo "SCP_USERNAME=${SCP_USERNAME}"
echo "SCP_PASSWORD=${SCP_PASSWORD}"
echo "DRY_RUN=${DRY_RUN:-true}"
echo "DRY_RUN=${DRY_RUN}"

- name: Make build script executable
run: chmod +x ./cicd/gcviewer-script.sh
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
GCViewer 1.36
=============

[![Build Status](https://app.travis-ci.com/chewiebug/GCViewer.svg?branch=develop)](https://app.travis-ci.com/chewiebug/GCViewer)
[![Build Status](https://github.com/chewiebug/GCViewer/actions/workflows/build-and-deploy.yaml/badge.svg?branch=develop)](https://github.com/chewiebug/GCViewer/actions/workflows/build-and-deploy.yaml?query=branch%3Adevelop)
[![codecov.io](https://codecov.io/github/chewiebug/GCViewer/coverage.svg?branch=develop)](https://codecov.io/github/chewiebug/GCViewer?branch=develop)
[![Download gcviewer](https://img.shields.io/sourceforge/dm/gcviewer.svg)](https://sourceforge.net/projects/gcviewer/files)

Expand Down
2 changes: 1 addition & 1 deletion act/execute-build-and-deploy-snapshot-release-workflow.bat
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ rem requirement for act builds to work: use the catthehacker/ubuntu:full-latest
rem all necessary secrets are set in the .env file
rem CAUTION: will do real deployments!
pushd ..
act push -W .github/workflows/build-and-deploy.yaml --matrix java:8 --env DRY_RUN=false --env GITHUB_REF_NAME=develop --secret-file .env
act push -W .github/workflows/build-and-deploy.yaml --matrix java:8 --var DRY_RUN=false --env GITHUB_REF_NAME=develop --secret-file .env
popd
2 changes: 1 addition & 1 deletion cicd/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# cicd
This directory contains a settings.xml + script file that can be used to
deploy to the SonaType OSS repository from a Travis CI build.
deploy to the SonaType OSS repository from a Github actions build.

The full instructions are here:
https://jausoft.com/blog/2025/09/07/publishing-on-sonatypes-central-maven-repo/
Expand Down