Skip to content

Commit 6e3486d

Browse files
committed
Add Themes.
1 parent 7bf62b7 commit 6e3486d

28 files changed

Lines changed: 2847 additions & 710 deletions

.github/workflows/build.yml

Lines changed: 20 additions & 220 deletions
Original file line numberDiff line numberDiff line change
@@ -1,246 +1,46 @@
1-
# GitHub Actions Workflow is created for testing and preparing the plugin release in the following steps:
2-
# - Validate Gradle Wrapper.
3-
# - Run 'test' and 'verifyPlugin' tasks.
4-
# - Run Qodana inspections.
5-
# - Run the 'buildPlugin' task and prepare artifact for further tests.
6-
# - Run the 'runPluginVerifier' task.
7-
# - Create a draft release.
8-
#
9-
# The workflow is triggered on push and pull_request events.
10-
#
11-
# GitHub Actions reference: https://help.github.com/en/actions
12-
#
13-
## JBIJPPTPL
14-
151
name: Build
2+
163
on:
17-
# Trigger the workflow on pushes to only the 'main' branch (this avoids duplicate checks being run e.g., for dependabot pull requests)
4+
workflow_dispatch:
185
push:
19-
branches: [ main ]
20-
# Trigger the workflow on any pull request
6+
branches:
7+
- main
218
pull_request:
9+
branches:
10+
- main
2211

23-
concurrency:
24-
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
25-
cancel-in-progress: true
26-
2712
jobs:
28-
29-
# Prepare the environment and build the plugin
3013
build:
31-
name: Build
14+
name: Build Plugin
3215
runs-on: ubuntu-latest
3316
steps:
17+
- name: Checkout Repository
18+
uses: actions/checkout@v5
3419

35-
# Free GitHub Actions Environment Disk Space
36-
- name: Maximize Build Space
37-
uses: jlumbroso/free-disk-space@v1.3.1
38-
with:
39-
tool-cache: false
40-
large-packages: false
41-
42-
# Check out the current repository
43-
- name: Fetch Sources
44-
uses: actions/checkout@v4
45-
46-
# Set up the Java environment for the next steps
4720
- name: Setup Java
48-
uses: actions/setup-java@v4
21+
uses: actions/setup-java@v5
4922
with:
5023
distribution: zulu
5124
java-version: 21
25+
cache: gradle
5226

53-
# Setup Gradle
5427
- name: Setup Gradle
5528
uses: gradle/actions/setup-gradle@v4
5629

57-
# Build plugin
5830
- name: Build plugin
5931
run: ./gradlew buildPlugin
6032

61-
# Prepare plugin archive content for creating artifact
62-
- name: Prepare Plugin Artifact
63-
id: artifact
64-
shell: bash
65-
run: |
66-
cd ${{ github.workspace }}/build/distributions
67-
FILENAME=`ls *.zip`
68-
unzip "$FILENAME" -d content
69-
70-
echo "filename=${FILENAME:0:-4}" >> $GITHUB_OUTPUT
71-
72-
# Store an already-built plugin as an artifact for downloading
73-
- name: Upload artifact
74-
uses: actions/upload-artifact@v4
75-
with:
76-
name: ${{ steps.artifact.outputs.filename }}
77-
path: ./build/distributions/content/*/*
78-
79-
# Run tests and upload a code coverage report
80-
test:
81-
name: Test
82-
needs: [ build ]
83-
runs-on: ubuntu-latest
84-
steps:
85-
86-
# Free GitHub Actions Environment Disk Space
87-
- name: Maximize Build Space
88-
uses: jlumbroso/free-disk-space@v1.3.1
89-
with:
90-
tool-cache: false
91-
large-packages: false
92-
93-
# Check out the current repository
94-
- name: Fetch Sources
95-
uses: actions/checkout@v4
96-
97-
# Set up the Java environment for the next steps
98-
- name: Setup Java
99-
uses: actions/setup-java@v4
100-
with:
101-
distribution: zulu
102-
java-version: 21
103-
104-
# Setup Gradle
105-
- name: Setup Gradle
106-
uses: gradle/actions/setup-gradle@v4
107-
with:
108-
cache-read-only: true
109-
110-
# Run tests
111-
- name: Run Tests
112-
run: ./gradlew check
113-
114-
# Collect Tests Result of failed tests
115-
- name: Collect Tests Result
116-
if: ${{ failure() }}
117-
uses: actions/upload-artifact@v4
118-
with:
119-
name: tests-result
120-
path: ${{ github.workspace }}/build/reports/tests
121-
122-
# Upload the Kover report to CodeCov
123-
- name: Upload Code Coverage Report
124-
uses: codecov/codecov-action@v5
125-
with:
126-
files: ${{ github.workspace }}/build/reports/kover/report.xml
127-
token: ${{ secrets.CODECOV_TOKEN }}
128-
129-
# Run Qodana inspections and provide a report
130-
inspectCode:
131-
name: Inspect code
132-
needs: [ build ]
133-
runs-on: ubuntu-latest
134-
permissions:
135-
contents: write
136-
checks: write
137-
pull-requests: write
138-
steps:
139-
140-
# Free GitHub Actions Environment Disk Space
141-
- name: Maximize Build Space
142-
uses: jlumbroso/free-disk-space@v1.3.1
143-
with:
144-
tool-cache: false
145-
large-packages: false
146-
147-
# Check out the current repository
148-
- name: Fetch Sources
149-
uses: actions/checkout@v4
150-
with:
151-
ref: ${{ github.event.pull_request.head.sha }} # to check out the actual pull request commit, not the merge commit
152-
fetch-depth: 0 # a full history is required for pull request analysis
153-
154-
# Set up the Java environment for the next steps
155-
- name: Setup Java
156-
uses: actions/setup-java@v4
157-
with:
158-
distribution: zulu
159-
java-version: 21
160-
161-
# Run Qodana inspections
162-
- name: Qodana - Code Inspection
163-
uses: JetBrains/qodana-action@v2025.1.1
164-
with:
165-
cache-default-branch-only: true
166-
167-
# Run plugin structure verification along with IntelliJ Plugin Verifier
168-
verify:
169-
name: Verify plugin
170-
needs: [ build ]
171-
runs-on: ubuntu-latest
172-
steps:
173-
174-
# Free GitHub Actions Environment Disk Space
175-
- name: Maximize Build Space
176-
uses: jlumbroso/free-disk-space@v1.3.1
177-
with:
178-
tool-cache: false
179-
large-packages: false
180-
181-
# Check out the current repository
182-
- name: Fetch Sources
183-
uses: actions/checkout@v4
33+
- name: Get Commit SHA
34+
id: vars
35+
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
18436

185-
# Set up the Java environment for the next steps
186-
- name: Setup Java
187-
uses: actions/setup-java@v4
188-
with:
189-
distribution: zulu
190-
java-version: 21
191-
192-
# Setup Gradle
193-
- name: Setup Gradle
194-
uses: gradle/actions/setup-gradle@v4
195-
with:
196-
cache-read-only: true
197-
198-
# Run Verify Plugin task and IntelliJ Plugin Verifier tool
199-
- name: Run Plugin Verification tasks
200-
run: ./gradlew verifyPlugin
201-
202-
# Collect Plugin Verifier Result
203-
- name: Collect Plugin Verifier Result
204-
if: ${{ always() }}
37+
- name: Upload JAR
20538
uses: actions/upload-artifact@v4
20639
with:
207-
name: pluginVerifier-result
208-
path: ${{ github.workspace }}/build/reports/pluginVerifier
209-
210-
# Prepare a draft release for GitHub Releases page for the manual verification
211-
# If accepted and published, the release workflow would be triggered
212-
releaseDraft:
213-
name: Release draft
214-
if: github.event_name != 'pull_request'
215-
needs: [ build, test, inspectCode, verify ]
216-
runs-on: ubuntu-latest
217-
permissions:
218-
contents: write
219-
steps:
220-
221-
# Check out the current repository
222-
- name: Fetch Sources
223-
uses: actions/checkout@v4
224-
225-
# Remove old release drafts by using the curl request for the available releases with a draft flag
226-
- name: Remove Old Release Drafts
227-
env:
228-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
229-
run: |
230-
gh api repos/{owner}/{repo}/releases \
231-
--jq '.[] | select(.draft == true) | .id' \
232-
| xargs -I '{}' gh api -X DELETE repos/{owner}/{repo}/releases/{}
40+
name: "alabaster-shmalabaster-jetbrains-${{ steps.vars.outputs.sha_short }}"
41+
path: build/libs/*.jar
23342

234-
# Create a new release draft which is not publicly visible and requires manual acceptance
235-
- name: Create Release Draft
236-
env:
237-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43+
- name: Output Unreleased Changes
23844
run: |
239-
VERSION=$(./gradlew properties --property version --quiet --console=plain | tail -n 1 | cut -f2- -d ' ')
240-
RELEASE_NOTE="./build/tmp/release_note.txt"
241-
./gradlew getChangelog --unreleased --no-header --quiet --console=plain --output-file=$RELEASE_NOTE
242-
243-
gh release create $VERSION \
244-
--draft \
245-
--title $VERSION \
246-
--notes-file $RELEASE_NOTE
45+
echo "# 🚧 Unreleased 🚧" >> $GITHUB_STEP_SUMMARY
46+
echo "$(./gradlew getChangelog --unreleased --no-header --console=plain -q)" >> $GITHUB_STEP_SUMMARY

0 commit comments

Comments
 (0)