-
Notifications
You must be signed in to change notification settings - Fork 6
51 lines (43 loc) · 1.57 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: build
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
# Root directory for doing Ghidra work (building, etc.)
root: ["/tmp/ghidra"]
# Ghidra build version(s)
version: [11.1.2]
include:
- version: 11.1.2
release_url: "https://github.com/NationalSecurityAgency/ghidra/releases/download/Ghidra_11.1.2_build"
filename: "ghidra_11.1.2_PUBLIC_20240709.zip"
directory: "ghidra_11.1.2_PUBLIC"
steps:
- uses: actions/checkout@v3
- name: Download Ghidra
run: |
wget -P ${{matrix.root}} -q ${{matrix.release_url}}/${{matrix.filename}}
unzip -d ${{matrix.root}} -q ${{matrix.root}}/${{matrix.filename}}
- name: Setup Java
uses: actions/setup-java@v3
with:
java-version: 17
distribution: temurin
- name: Build plugin via gradle
run: gradle -PGHIDRA_INSTALL_DIR=${{matrix.root}}/${{matrix.directory}} -PZIP_NAME_PREFIX=ghidra_${{matrix.version}}
# Uploading a ZIP file as an artifact creates a double-ZIP
- name: Fix artifact ZIP
run: unzip -d dist/${{matrix.version}} dist/*_${{matrix.version}}_*.zip
# Upload the unzipped contents as the artifact to create a Ghidra-loadable ZIP file
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: ghidra_${{matrix.version}}_REAIT
path: dist/${{matrix.version}}/*
if-no-files-found: error