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
30 changes: 30 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"name": "Awesome Java UI - Java 25",
"image": "mcr.microsoft.com/devcontainers/java:25",
"features": {
"ghcr.io/devcontainers/features/java:1": {
"version": "25",
"installMaven": "false",
"installGradle": "false"
}
},
"customizations": {
"vscode": {
"extensions": [
"vscjava.vscode-java-pack",
"GitHub.copilot",
"GitHub.copilot-chat"
],
"settings": {
"java.configuration.runtimes": [
{
"name": "JavaSE-25",
"path": "/usr/local/sdkman/candidates/java/current"
}
]
}
}
},
"postCreateCommand": "bash -c 'cd /tmp && curl -Ls https://sh.jbang.dev -o jbang-install.sh && bash jbang-install.sh app setup && rm jbang-install.sh'",
"remoteUser": "vscode"
}
14 changes: 14 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,20 @@ The front matter schema:
- Automatically builds and deploys to GitHub Pages on push to main
- Uses JBang to run the build script in the CI environment

### Copilot Java 25 Workflow
- GitHub Actions workflow in `.github/workflows/copilot-setup-steps.yml`
- Ensures Java 25 environment for Copilot agents on pull requests
- Includes JBang setup with caching for improved performance
- Validates the build process with Java 25
- Can be manually triggered via workflow_dispatch

### Development Environment
- DevContainer configuration in `.devcontainer/devcontainer.json`
- Pre-configured with Java 25 for GitHub Codespaces and VS Code
- Includes GitHub Copilot extensions and Java development tools
- Automatically sets up JBang on container creation
- Provides consistent development environment across all contributors

### Local Development
- Output directory (`_site/`) is gitignored
- Rebuild the site locally after markdown changes to preview
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-site.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
java-version: '25'

- name: Setup JBang
uses: jbangdev/setup-jbang@main
uses: jbangdev/setup-jbang@v0.1.1

- name: Build site with JBang
# this outputs to the /docs folder
Expand Down
46 changes: 46 additions & 0 deletions .github/workflows/copilot-setup-steps.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: "Copilot Setup Steps"

on:
workflow_dispatch:
push:
paths:
- .github/workflows/copilot-setup-steps.yml
pull_request:
paths:
- .github/workflows/copilot-setup-steps.yml

jobs:
# This job name MUST be exactly "copilot-setup-steps"
copilot-setup-steps:
runs-on: ubuntu-latest

permissions:
contents: read

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up JDK 25
uses: actions/setup-java@v4
with:
java-version: '25'
distribution: 'temurin'

- name: Setup JBang
uses: jbangdev/setup-jbang@v0.1.1

- name: Verify Java version
run: java -version

- name: Cache JBang dependencies
uses: actions/cache@v4
with:
path: |
~/.jbang
key: ${{ runner.os }}-jbang-${{ hashFiles('**/*.java') }}
restore-keys: |
${{ runner.os }}-jbang-

- name: Download dependencies
run: jbang run --fresh build.java
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,15 @@ Visit [https://awesome-java-ui.com](https://awesome-java-ui.com)

## Quick Start

### Option 1: GitHub Codespaces or VS Code DevContainer
The easiest way to get started is with our pre-configured development environment:

1. Open this repository in GitHub Codespaces or VS Code with DevContainers
2. The environment will automatically set up Java 25 and JBang
3. Run `jbang run build.java` to build the site
4. Open `_site/index.html` in a browser to view the site

### Option 2: Local Development
**Prerequisites:**
- Java 25+
- JBang
Expand Down