Skip to content

Commit db97263

Browse files
committed
Squashed commit of the following:
commit 96ce611 Author: Stef Tervelde <[email protected]> Date: Tue Sep 23 14:14:56 2025 +0200 Add Processing build in libraries commit 374ba2c Author: Stef Tervelde <[email protected]> Date: Tue Sep 23 13:58:22 2025 +0200 Support multiple library directories in LibrariesTask Refactored LibrariesTask to accept multiple input directories via ConfigurableFileCollection instead of a single DirectoryProperty. commit e097d68 Author: Stef Tervelde <[email protected]> Date: Tue Sep 23 13:34:44 2025 +0200 Enhance PDE source set and preprocessing in ProcessingPlugin Added comments and structure for improved clarity. Also added a placeholder test for internal libraries in ProcessingPluginTest. commit 2b8b151 Author: Stef Tervelde <[email protected]> Date: Tue Sep 23 12:38:11 2025 +0200 Add stdio connection to PDE and stub test for code jars commit d5e48e4 Author: Stef Tervelde <[email protected]> Date: Tue Sep 23 12:27:17 2025 +0200 Add test for importing and using Processing libraries Introduces a helper to create temporary Processing libraries and implements a test that imports and uses a custom library in a Processing sketch. This enhances test coverage for library integration in the Processing Gradle plugin. commit 6b873ce Author: Stef Tervelde <[email protected]> Date: Tue Sep 23 12:01:56 2025 +0200 Publishing app:utils to internal library commit b2f79f6 Author: Stef Tervelde <[email protected]> Date: Mon Sep 22 14:21:27 2025 +0200 Include root-level Java files in source set Uncommented and updated the configuration to include all .java files at the project root in the source set. This ensures that Java files located directly in the project directory are recognized and compiled. commit 4aeff01 Merge: 046a216 72db9b7 Author: Stef Tervelde <[email protected]> Date: Mon Sep 22 14:07:25 2025 +0200 Merge branch 'main' into gradle-runner commit 046a216 Merge: 570e9db 198f593 Author: Stef Tervelde <[email protected]> Date: Mon Sep 8 18:27:48 2025 +0200 Merge branch 'main' into gradle-runner commit 570e9db Author: Stef Tervelde <[email protected]> Date: Fri Jul 18 21:42:08 2025 +0200 Automatically download jdk commit 578c287 Author: Stef Tervelde <[email protected]> Date: Fri Jul 18 10:43:33 2025 +0200 Build on save commit fdc43dc Author: Stef Tervelde <[email protected]> Date: Thu Jul 17 15:49:40 2025 +0200 Hot Reloading plugin commit 0c674ad Author: Stef Tervelde <[email protected]> Date: Thu Jul 17 12:13:56 2025 +0200 Initial Gradle Plugin configuration commit f916d27 Author: Stef Tervelde <[email protected]> Date: Wed Jul 16 11:26:37 2025 +0200 Adding a settings panel to the editor For upcoming plugin support we need a way to enable plugins based on each sketch commit 550200c Author: Stef Tervelde <[email protected]> Date: Wed Jul 9 09:41:40 2025 +0200 Comments and planning commit c55e286 Author: Stef Tervelde <[email protected]> Date: Tue Jul 8 12:23:05 2025 +0200 Speed up gradle compilations commit b712390 Author: Stef Tervelde <[email protected]> Date: Tue Jul 8 11:59:28 2025 +0200 Fixed rename Windres task commit a36c8a3 Author: Stef Tervelde <[email protected]> Date: Tue Jul 8 10:31:12 2025 +0200 Plugin tests bugfixes commit 7379166 Author: Stef Tervelde <[email protected]> Date: Tue Jul 8 10:26:16 2025 +0200 Processing Plugin tests & Refactor commit b64505d Author: Stef Tervelde <[email protected]> Date: Mon Jul 7 16:21:59 2025 +0200 Gradle Service refactor commit a11d2ff Author: Stef Tervelde <[email protected]> Date: Mon Jul 7 15:22:21 2025 +0200 Logging sketches to separate stream & small refactor commit 5729e88 Author: Stef Tervelde <[email protected]> Date: Mon Jul 7 11:01:58 2025 +0200 Show error logs to the user commit b709fe3 Merge: cebc352 d7c6aeb Author: Stef Tervelde <[email protected]> Date: Fri Jul 4 07:36:32 2025 +0200 Merge branch 'gradle-runner' of https://github.com/Stefterv/processing4 into gradle-runner commit cebc352 Author: Stef Tervelde <[email protected]> Date: Fri Jul 4 07:36:31 2025 +0200 Snap support commit d7c6aeb Author: Stef Tervelde <[email protected]> Date: Fri Jul 4 06:54:50 2025 +0200 Also copy Untitled sketches commit 24cb4f4 Author: Stef Tervelde <[email protected]> Date: Fri Jul 4 06:23:00 2025 +0200 Improved Error reporting commit e727dbf Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 21:33:12 2025 +0200 Support for readonly sketches commit b165d0a Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 21:25:52 2025 +0200 Add all library jars commit 772567c Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 20:34:37 2025 +0200 Build system indicators, Language keys and filtering SLF4J warnings commit efd03db Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 15:58:02 2025 +0200 Fixed gradle runner issues commit 5409912 Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 13:42:41 2025 +0200 Improved Gradle Error logging commit 1762b74 Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 11:56:34 2025 +0200 Simplified Gradle Service, improved sketch logging, fixed toolbar state commit e6474e1 Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 10:29:20 2025 +0200 Small tweaks and wrote motivation for Gradle Build system commit 67de82f Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 09:53:14 2025 +0200 Removed error & out streams, has been piped directly into System commit bd5aba4 Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 09:50:39 2025 +0200 Allowing libraries folder to not exist, but log instead commit fcb554a Author: Stef Tervelde <[email protected]> Date: Wed Jul 2 09:42:19 2025 +0200 Rename gradle plugin and further planning commit 1c42961 Author: Stef Tervelde <[email protected]> Date: Tue Jul 1 17:35:32 2025 +0200 Gradle Task error printing commit 4cca647 Author: Stef Tervelde <[email protected]> Date: Tue Jul 1 17:02:03 2025 +0200 Updated error reporting commit 0d1fcc4 Author: Stef Tervelde <[email protected]> Date: Tue Jul 1 14:40:30 2025 +0200 Added documentation and todo's commit 0299209 Author: Stef Tervelde <[email protected]> Date: Tue Jul 1 12:59:34 2025 +0200 Squashed commit of the following: commit 3a1aa8e Author: Stef Tervelde <[email protected]> Date: Tue Jul 1 12:53:59 2025 +0200 Restore welcome & Cleanup commit 7d94b30 Author: Stef Tervelde <[email protected]> Date: Tue Jul 1 12:20:17 2025 +0200 PR Cleanup commit 27764e9 Author: Stef Tervelde <[email protected]> Date: Mon Jun 23 13:33:50 2025 +0200 Update Toolbar.kt commit 97fc4c2 Author: Stef Tervelde <[email protected]> Date: Mon Jun 23 13:30:47 2025 +0200 Removed background job differentiation commit 85566c8 Author: Stef Tervelde <[email protected]> Date: Mon Jun 23 13:09:11 2025 +0200 CLI Compatibility commit 7f2f2b6 Merge: 1c8581e bf34ade Author: Stef Tervelde <[email protected]> Date: Mon Jun 23 11:14:57 2025 +0200 Merge branch 'main' into runner commit 1c8581e Author: Stef Tervelde <[email protected]> Date: Thu May 15 13:39:21 2025 +0200 Move Gradle connection into GradleJob commit d742002 Author: Stef Tervelde <[email protected]> Date: Thu May 15 10:10:33 2025 +0200 Exclude jnilib from sources commit 2c9ee1c Author: Stef Tervelde <[email protected]> Date: Thu May 15 09:51:08 2025 +0200 Linux Platform addition commit 49988e9 Author: Stef Tervelde <[email protected]> Date: Thu May 15 09:34:44 2025 +0200 Use forward slashes on Windows commit da5092e Author: Stef Tervelde <[email protected]> Date: Thu May 15 09:10:11 2025 +0200 Add support for .java files & Cleanup commit ab7c216 Author: Stef Tervelde <[email protected]> Date: Thu May 15 08:15:11 2025 +0200 Preferences in the PDE will now be read from system before looking at files commit 7775d01 Author: Stef Tervelde <[email protected]> Date: Wed May 14 18:07:50 2025 +0200 Identified Bugs commit 80c48f2 Author: Stef Tervelde <[email protected]> Date: Wed May 14 17:59:07 2025 +0200 Windows Bugfix commit 5ad43e0 Author: Stef Tervelde <[email protected]> Date: Wed May 14 17:51:57 2025 +0200 Set a default tab size commit 2f99a69 Author: Stef Tervelde <[email protected]> Date: Wed May 14 16:14:59 2025 +0200 Bundle necessary plugins commit f9b94c5 Author: Stef Tervelde <[email protected]> Date: Wed May 14 15:17:55 2025 +0200 Only make parent dirs commit 982c111 Author: Stef Tervelde <[email protected]> Date: Wed May 14 15:11:54 2025 +0200 Show debug on gradle tests commit 917d0d3 Author: Stef Tervelde <[email protected]> Date: Wed May 14 15:08:47 2025 +0200 Listen for folder changes commit 12ce442 Author: Stef Tervelde <[email protected]> Date: Wed May 14 14:25:06 2025 +0200 Fix saved files using an old version commit 04ac9f2 Author: Stef Tervelde <[email protected]> Date: Wed May 14 13:47:21 2025 +0200 Plugin rework for caching heavy work commit e31d37d Merge: df1277e 540d299 Author: Stef Tervelde <[email protected]> Date: Wed May 14 10:43:43 2025 +0200 Merge branch 'main' into runner commit df1277e Author: Stef Tervelde <[email protected]> Date: Wed May 14 10:39:22 2025 +0200 Disabled modern UI for now. Added preference instead commit c5c3b2f Author: Stef Tervelde <[email protected]> Date: Mon Apr 21 14:04:39 2025 +0200 Added todos commit 612126a Merge: 3e89bfe ecd219b Author: Stef Tervelde <[email protected]> Date: Thu Apr 17 12:37:06 2025 +0200 Merge branch 'main' into runner commit 3e89bfe Merge: efa77bb 7489870 Author: Stef Tervelde <[email protected]> Date: Thu Apr 17 12:34:57 2025 +0200 Merge branch 'runner' of https://github.com/Stefterv/processing4 into runner commit efa77bb Author: Stef Tervelde <[email protected]> Date: Tue Apr 1 18:19:58 2025 +0200 Cleanup [skip ci] commit 7489870 Author: Stef Tervelde <[email protected]> Date: Tue Apr 1 18:19:58 2025 +0200 Cleanup [skip ci] commit 97ec5e4 Merge: 221ee28 3d6a6ce Author: Stef Tervelde <[email protected]> Date: Tue Apr 1 17:54:41 2025 +0200 Merge branch 'gradle-welcome-screen' into runner commit 221ee28 Author: Stef Tervelde <[email protected]> Date: Tue Apr 1 17:53:48 2025 +0200 Toolbar UI design start commit a870cd0 Author: Stef Tervelde <[email protected]> Date: Tue Apr 1 10:14:22 2025 +0200 GradleJob Refactor commit 2269fd3 Author: Stef Tervelde <[email protected]> Date: Tue Apr 1 09:15:47 2025 +0200 Gradle Runner, build script management commit 6758d68 Author: Stef Tervelde <[email protected]> Date: Mon Mar 31 18:40:19 2025 +0200 Richer console output and richer exception output commit 15114a1 Author: Stef Tervelde <[email protected]> Date: Mon Mar 31 15:00:12 2025 +0200 Retry vm debug connection commit 36ce0ab Author: Stef Tervelde <[email protected]> Date: Mon Mar 31 12:05:58 2025 +0200 Runner: Fixing build errors commit 701f9f5 Author: Stef Tervelde <[email protected]> Date: Sun Mar 30 23:58:36 2025 +0200 Gradle Runner PoC Refactor commit 947a90e Author: Stef Tervelde <[email protected]> Date: Sun Mar 30 14:51:48 2025 +0200 Toolbar functionality PoC commit 3d6a6ce Merge: f7f22c5 2222331 Author: Stef Tervelde <[email protected]> Date: Sun Mar 30 08:52:37 2025 +0200 Merge branch 'processing:main' into gradle-welcome-screen commit 4602ef1 Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 22:50:35 2025 +0100 Fixes for windows commit 0d3795f Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 22:31:47 2025 +0100 Gradle Runner, more variables commit ab38e5f Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 20:54:02 2025 +0100 Arguments refactor commit 17acb01 Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 20:10:15 2025 +0100 Copy running JDK rather than download commit b534c26 Merge: d6cb3ee 2222331 Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 18:17:20 2025 +0100 Merge branch 'main' into runner commit d6cb3ee Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 10:20:17 2025 +0100 Fix for signing release commit bf82d53 Merge: 73dfa0a dd823a7 Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 10:17:06 2025 +0100 Merge branch 'runner' of https://github.com/Stefterv/processing4 into runner commit 73dfa0a Author: Stef Tervelde <[email protected]> Date: Sat Mar 29 10:17:04 2025 +0100 Only sign with signing set up commit 41ef1cc Author: Stef Tervelde <[email protected]> Date: Fri Mar 28 09:00:23 2025 +0100 Fix plugin name in tests commit dd823a7 Author: Stef Tervelde <[email protected]> Date: Fri Mar 28 09:00:23 2025 +0100 Fix plugin name in tests commit 3a14ff4 Author: Stef Tervelde <[email protected]> Date: Fri Mar 28 08:18:53 2025 +0100 Added Stubs commit 00f8afa Merge: 700599e 1ab2359 Author: Stef Tervelde <[email protected]> Date: Fri Mar 28 08:13:11 2025 +0100 Merge branch 'schema-threading' into runner commit 700599e Merge: 1fae461 499d200 Author: Stef Tervelde <[email protected]> Date: Fri Mar 28 08:13:06 2025 +0100 Merge branch 'main' into runner commit 1fae461 Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 21:37:55 2025 +0100 UI Cleanup commit f762a3e Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 20:05:01 2025 +0100 Added debugging commit c2071a0 Merge: f453eca 8fb9ef5 Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 18:23:23 2025 +0100 Merge branch 'hide-scrollbars' into runner commit f453eca Merge: 8f47d21 694eb0c Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 18:03:34 2025 +0100 Merge remote-tracking branch 'upstream/fix-jdk-requirement' into runner commit 8f47d21 Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 18:00:15 2025 +0100 Scan libaries for dependencies commit 5d71244 Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 14:58:11 2025 +0100 Plugin rework commit e164fe4 Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 13:01:33 2025 +0100 Gradle variables from Processing, Group resolution commit 672c2ac Author: Stef Tervelde <[email protected]> Date: Thu Mar 27 11:51:08 2025 +0100 Removed the need for settings.gradle.kts & Embedding maven repo commit cdec594 Author: Stef Tervelde <[email protected]> Date: Wed Mar 26 18:39:04 2025 +0100 Added export support commit 3ad3654 Author: Stef Tervelde <[email protected]> Date: Wed Mar 26 17:25:51 2025 +0100 Gradle Runner visual styling commit bc063e8 Author: Stef Tervelde <[email protected]> Date: Wed Mar 26 14:17:25 2025 +0100 Gradle Runner PoC commit 47d3428 Author: Stef Tervelde <[email protected]> Date: Sun Mar 23 18:18:54 2025 +0100 More todo's commit 29d76eb Merge: ba49656 9760a63 Author: Stef Tervelde <[email protected]> Date: Sun Mar 23 17:58:39 2025 +0100 Merge branch 'processing:main' into gradle-plugin commit ba49656 Author: Stef Tervelde <[email protected]> Date: Tue Mar 18 10:15:40 2025 +0100 Adding tests and direct linking commit e01d02a Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 15:31:25 2025 +0100 Update settings.gradle.kts commit b0b12dd Merge: 7e6c97a ad5c27e Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 15:14:35 2025 +0100 Merge branch 'gradle-preprocessor' into gradle-plugin commit ad5c27e Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 15:11:24 2025 +0100 Apply same parser & lexer fixes from before commit 743ea14 Merge: c28a267 8e8f7dc Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 13:53:40 2025 +0100 Merge branch 'main' into gradle-preprocessor commit 7e6c97a Merge: f126d4b 8e8f7dc Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 13:43:21 2025 +0100 Merge branch 'main' into gradle-plugin commit f7f22c5 Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 10:40:37 2025 +0100 Create Directory as well commit d17ca0c Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 10:36:35 2025 +0100 Removed PlatformStart and create new file if doesn't exist commit b0e7f96 Author: Stef Tervelde <[email protected]> Date: Mon Mar 17 10:28:12 2025 +0100 Added initial tests commit 0df4dc0 Merge: 6974811 8e8f7dc Author: Stef Tervelde <[email protected]> Date: Sun Mar 16 21:18:22 2025 +0100 Merge branch 'main' into gradle-welcome-screen commit 6974811 Merge: 7452d65 1455512 Author: Stef Tervelde <[email protected]> Date: Tue Mar 11 20:42:46 2025 +0100 Merge branch 'test-schema' into gradle-welcome-screen commit 7452d65 Merge: babf54e fe152b7 Author: Stef Tervelde <[email protected]> Date: Fri Mar 7 15:07:56 2025 +0100 Merge branch 'main' into gradle-welcome-screen commit c28a267 Merge: e188336 fe152b7 Author: Stef Tervelde <[email protected]> Date: Fri Mar 7 15:06:27 2025 +0100 Merge branch 'processing:main' into gradle-preprocessor commit f126d4b Merge: da852b4 fe152b7 Author: Stef Tervelde <[email protected]> Date: Fri Mar 7 15:06:08 2025 +0100 Merge branch 'processing:main' into gradle-plugin commit babf54e Merge: 0e56f89 00c5760 Author: Stef Tervelde <[email protected]> Date: Mon Feb 10 17:58:35 2025 +0100 Merge branch 'gradle-loggin' into gradle-welcome-screen commit 0e56f89 Merge: 54944af 29b557a Author: Stef Tervelde <[email protected]> Date: Sun Feb 9 21:15:36 2025 +0100 Merge branch 'main-gradle' into gradle-welcome-screen commit 54944af Author: Stef Tervelde <[email protected]> Date: Sun Feb 9 14:36:37 2025 +0100 Welcome Screen: JDK Module commit 8d8bd01 Author: Stef Tervelde <[email protected]> Date: Sun Feb 9 13:54:07 2025 +0100 Welcome Screen: Close Functionality commit 3df4da9 Author: Stef Tervelde <[email protected]> Date: Sun Feb 9 12:57:55 2025 +0100 Welcome Screen: Bugfixes commit cb184fb Author: Stef Tervelde <[email protected]> Date: Sun Feb 9 12:19:33 2025 +0100 Welcome Screen: Layout fixes commit 3d81b02 Author: Stef Tervelde <[email protected]> Date: Sat Feb 8 22:47:28 2025 +0100 Welcome Screen: Language selection commit b0c61a4 Author: Stef Tervelde <[email protected]> Date: Sat Feb 8 11:10:33 2025 +0100 Welcome Screen: Load & Display examples commit 2f12d13 Author: Stef Tervelde <[email protected]> Date: Fri Feb 7 21:53:49 2025 +0100 Saveable/Reactive Preferences commit 8ed2d1b Author: Stef Tervelde <[email protected]> Date: Fri Feb 7 16:34:23 2025 +0100 Welcome Screen: WIP commit 5c020dd Author: Stef Tervelde <[email protected]> Date: Fri Feb 7 15:49:25 2025 +0100 Welcome Screen: Initial Layout commit bd3a77e Author: Stef Tervelde <[email protected]> Date: Fri Feb 7 12:09:58 2025 +0100 Welcome Screen: Window Abstraction commit b1910de Author: Stef Tervelde <[email protected]> Date: Fri Feb 7 11:24:30 2025 +0100 Welcome Screen: Initial Frame commit da852b4 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 20:54:32 2025 +0100 Fullscreen support commit 44ab816 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 20:38:27 2025 +0100 disable full screen from settings and fixed a few bugs commit e188336 Merge: df745bb 3f3e7d7 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 13:03:51 2025 +0100 Merge branch 'main-gradle' into gradle/preprocessor commit 031d304 Merge: 25e147e 3f3e7d7 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 13:03:12 2025 +0100 Merge branch 'main-gradle' into gradle/plugin commit 25e147e Merge: 7f00d5b 3b9aea1 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 12:56:55 2025 +0100 Merge branch 'main-gradle' into gradle/plugin commit df745bb Merge: f016cc4 3b9aea1 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 12:56:38 2025 +0100 Merge branch 'main-gradle' into gradle/preprocessor commit 7f00d5b Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 12:36:18 2025 +0100 added example of plugin usage commit f4d7fbf Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 09:19:08 2025 +0100 Changed naming commit 1b8a8ed Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 09:10:42 2025 +0100 Gradle Plugin from PoC commit 5468da0 Author: Stef Tervelde <[email protected]> Date: Tue Feb 4 16:18:29 2025 +0100 Removed outdated ant backwards compatibility marks commit 23c8a46 Author: Stef Tervelde <[email protected]> Date: Mon Feb 3 12:07:01 2025 +0100 - Imports cleanup - Disable system look & feel on macOS for readability - Cleaned unnecessary space - Cleaned finished TODO commit f016cc4 Author: Stef Tervelde <[email protected]> Date: Wed Feb 5 12:01:47 2025 +0100 Removed core dependency from the pre-processor commit 971d98b Author: Stef Tervelde <[email protected]> Date: Thu Jan 30 22:59:16 2025 +0100 Preprocessor with antlr Plugin
1 parent 72db9b7 commit db97263

File tree

15 files changed

+901
-10
lines changed

15 files changed

+901
-10
lines changed

.gitignore

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,19 @@ gen-external-apklibs
6666
hs_err_pid*
6767
replay_pid*
6868

69+
# Maven ignores
70+
.kotlin
71+
.gradle
72+
.build/
73+
/core/build/
74+
/build/publish/
75+
/app/build
76+
/java/build/
77+
/build/reports
78+
/java/bin
79+
/java/libraries/svg/bin
80+
/java/preprocessor/build
81+
/java/lsp/build
6982
### Gradle ###
7083
.gradle
7184
**/build/
@@ -123,4 +136,16 @@ generated/
123136
!java/libraries/serial/library/jssc.jar
124137
/app/windows/obj
125138
/java/gradle/build
139+
/core/examples/build
126140
/java/gradle/example/.processing
141+
/app/windows/obj
142+
/java/android/example/build
143+
/java/android/example/.processing
144+
/java/gradle/example/build
145+
/java/gradle/example/gradle/wrapper/gradle-wrapper.jar
146+
/java/gradle/example/gradle/wrapper/gradle-wrapper.properties
147+
/java/gradle/example/gradlew
148+
/java/gradle/example/gradlew.bat
149+
/java/gradle/example/.kotlin/errors
150+
/java/gradle/hotreload/build
151+
*.iml

app/utils/build.gradle.kts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
plugins {
22
id("java")
3+
alias(libs.plugins.mavenPublish)
34
}
45

56
repositories {
@@ -11,6 +12,15 @@ dependencies {
1112
testImplementation("org.junit.jupiter:junit-jupiter")
1213
}
1314

15+
publishing{
16+
repositories{
17+
maven {
18+
name = "App"
19+
url = uri(project(":app").layout.buildDirectory.dir("resources-bundled/common/repository").get().asFile.absolutePath)
20+
}
21+
}
22+
}
23+
1424
tasks.test {
1525
useJUnitPlatform()
1626
}

core/build.gradle.kts

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ sourceSets{
1515
main{
1616
java{
1717
srcDirs("src")
18+
exclude("**/*.jnilib")
1819
}
1920
resources{
2021
srcDirs("src")
@@ -34,10 +35,21 @@ dependencies {
3435

3536
testImplementation(libs.junit)
3637
}
38+
publishing{
39+
repositories{
40+
maven {
41+
name = "App"
42+
url = uri(project(":app").layout.buildDirectory.dir("resources-bundled/common/repository").get().asFile.absolutePath)
43+
}
44+
}
45+
}
3746

3847
mavenPublishing{
3948
publishToMavenCentral(SonatypeHost.CENTRAL_PORTAL)
40-
signAllPublications()
49+
50+
// Only sign if signing is set up
51+
if(project.hasProperty("signing.keyId") || project.hasProperty("signing.signingInMemoryKey"))
52+
signAllPublications()
4153

4254
pom{
4355
name.set("Processing Core")
@@ -77,3 +89,6 @@ tasks.withType<Jar> {
7789
tasks.compileJava{
7890
options.encoding = "UTF-8"
7991
}
92+
tasks.javadoc{
93+
options.encoding = "UTF-8"
94+
}

core/src/processing/core/PApplet.java

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -705,7 +705,7 @@ public class PApplet implements PConstants {
705705
protected boolean exitCalled;
706706

707707
// ok to be static because it's not possible to mix enabled/disabled
708-
static protected boolean disableAWT;
708+
static protected boolean disableAWT = System.getProperty("processing.awt.disable", "false").equals("true");;
709709

710710
// messages to send if attached as an external vm
711711

@@ -9940,19 +9940,21 @@ static public void runSketch(final String[] args,
99409940
System.exit(1);
99419941
}
99429942

9943-
boolean external = false;
9944-
int[] location = null;
9945-
int[] editorLocation = null;
9943+
boolean external = System.getProperty("processing.external", "false").equals("true");;
9944+
int[] location = System.getProperty("processing.location", null) != null ?
9945+
parseInt(split(System.getProperty("processing.location"), ',')) : null;
99469946

9947+
int[] editorLocation = System.getProperty("processing.editor.location", null) != null ?
9948+
parseInt(split(System.getProperty("processing.editor.location"), ',')) : null;
99479949
String name = null;
99489950
int windowColor = 0;
99499951
int stopColor = 0xff808080;
9950-
boolean hideStop = false;
9952+
boolean hideStop = System.getProperty("processing.stop.hide", "false").equals("true");
99519953

99529954
int displayNum = -1; // use default
9953-
boolean present = false;
9954-
boolean fullScreen = false;
9955-
float uiScale = 0;
9955+
boolean present = System.getProperty("processing.present", "false").equals("true");
9956+
boolean fullScreen = System.getProperty("processing.fullscreen", "false").equals("true");
9957+
float uiScale = parseInt(System.getProperty("processing.uiScale", "0"), 0);
99569958

99579959
String param, value;
99589960
String folder = calcSketchPath();

java/gradle/build.gradle.kts

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
plugins{
2+
`java-gradle-plugin`
3+
alias(libs.plugins.gradlePublish)
4+
5+
kotlin("jvm") version libs.versions.kotlin
6+
}
7+
8+
repositories {
9+
mavenCentral()
10+
maven("https://jogamp.org/deployment/maven")
11+
}
12+
13+
dependencies{
14+
implementation(project(":java:preprocessor"))
15+
16+
implementation(libs.composeGradlePlugin)
17+
implementation(libs.kotlinGradlePlugin)
18+
implementation(libs.kotlinComposePlugin)
19+
20+
testImplementation(project(":core"))
21+
testImplementation(libs.junit)
22+
}
23+
24+
// TODO: CI/CD for publishing the plugin to the Gradle Plugin Portal
25+
gradlePlugin{
26+
plugins{
27+
create("processing.java"){
28+
id = "org.processing.java"
29+
implementationClass = "org.processing.java.gradle.ProcessingPlugin"
30+
}
31+
}
32+
}
33+
publishing{
34+
repositories{
35+
mavenLocal()
36+
maven {
37+
name = "App"
38+
url = uri(project(":app").layout.buildDirectory.dir("resources-bundled/common/repository").get().asFile.absolutePath)
39+
}
40+
}
41+
}

java/gradle/example/brightness.pde

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/**
2+
* Brightness
3+
* by Rusty Robison.
4+
*
5+
* Brightness is the relative lightness or darkness of a color.
6+
* Move the cursor vertically over each bar to alter its brightness.
7+
*/
8+
9+
int barWidth = 20;
10+
int lastBar = -1;
11+
12+
13+
void setup() {
14+
size(640, 360, P2D);
15+
colorMode(HSB, width, 100, height);
16+
noStroke();
17+
background(0);
18+
}
19+
20+
void draw() {
21+
int whichBar = mouseX / barWidth;
22+
if (whichBar != lastBar) {
23+
int barX = whichBar * barWidth;
24+
fill(barX, 100, mouseY);
25+
rect(barX, 0, barWidth, height);
26+
lastBar = whichBar;
27+
}
28+
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
plugins{
2+
id("org.processing.java")
3+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
rootProject.name = "processing-gradle-plugin-demo"
2+
3+
pluginManagement {
4+
includeBuild("../../../")
5+
}
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
package org.processing.java.gradle
2+
3+
import org.gradle.api.DefaultTask
4+
import org.gradle.api.GradleException
5+
import org.gradle.api.file.RegularFileProperty
6+
import org.gradle.api.tasks.InputFile
7+
import org.gradle.api.tasks.TaskAction
8+
import java.io.File
9+
import java.io.ObjectInputStream
10+
11+
/*
12+
* The DependenciesTask resolves the dependencies for the sketch based on the libraries used
13+
*/
14+
abstract class DependenciesTask: DefaultTask() {
15+
@InputFile
16+
val librariesMetaData: RegularFileProperty = project.objects.fileProperty()
17+
18+
@InputFile
19+
val sketchMetaData: RegularFileProperty = project.objects.fileProperty()
20+
21+
init{
22+
librariesMetaData.convention(project.layout.buildDirectory.file("processing/libraries"))
23+
sketchMetaData.convention(project.layout.buildDirectory.file("processing/sketch"))
24+
}
25+
26+
@TaskAction
27+
fun execute() {
28+
val sketchMetaFile = sketchMetaData.get().asFile
29+
val librariesMetaFile = librariesMetaData.get().asFile
30+
31+
val libraries = librariesMetaFile.inputStream().use { input ->
32+
ObjectInputStream(input).readObject() as ArrayList<LibrariesTask.Library>
33+
}
34+
35+
val sketch = sketchMetaFile.inputStream().use { input ->
36+
ObjectInputStream(input).readObject() as PDETask.SketchMeta
37+
}
38+
39+
val dependencies = mutableSetOf<File>()
40+
41+
// Loop over the import statements in the sketch and import the relevant jars from the libraries
42+
sketch.importStatements.forEach import@{ statement ->
43+
libraries.forEach { library ->
44+
library.jars.forEach { jar ->
45+
jar.classes.forEach { className ->
46+
if (className.startsWith(statement)) {
47+
dependencies.addAll(library.jars.map { it.path } )
48+
return@import
49+
}
50+
}
51+
}
52+
}
53+
}
54+
project.dependencies.add("implementation", project.files(dependencies) )
55+
56+
// TODO: Mutating the dependencies of configuration ':implementation' after it has been resolved or consumed. This
57+
58+
// TODO: Add only if user is compiling for P2D or P3D
59+
// Add JOGL and Gluegen dependencies
60+
project.dependencies.add("runtimeOnly", "org.jogamp.jogl:jogl-all-main:2.5.0")
61+
project.dependencies.add("runtimeOnly", "org.jogamp.gluegen:gluegen-rt:2.5.0")
62+
63+
val os = System.getProperty("os.name").lowercase()
64+
val arch = System.getProperty("os.arch").lowercase()
65+
66+
val variant = when {
67+
os.contains("mac") -> "macosx-universal"
68+
os.contains("win") && arch.contains("64") -> "windows-amd64"
69+
os.contains("linux") && arch.contains("aarch64") -> "linux-aarch64"
70+
os.contains("linux") && arch.contains("arm") -> "linux-arm"
71+
os.contains("linux") && arch.contains("amd64") -> "linux-amd64"
72+
else -> throw GradleException("Unsupported OS/architecture: $os / $arch")
73+
}
74+
75+
project.dependencies.add("runtimeOnly", "org.jogamp.gluegen:gluegen-rt:2.5.0:natives-$variant")
76+
project.dependencies.add("runtimeOnly", "org.jogamp.jogl:nativewindow:2.5.0:natives-$variant")
77+
project.dependencies.add("runtimeOnly", "org.jogamp.jogl:newt:2.5.0:natives-$variant")
78+
}
79+
}
Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
package org.processing.java.gradle
2+
3+
import org.gradle.api.DefaultTask
4+
import org.gradle.api.file.ConfigurableFileCollection
5+
import org.gradle.api.file.RegularFileProperty
6+
import org.gradle.api.tasks.InputFiles
7+
import org.gradle.api.tasks.OutputFile
8+
import org.gradle.api.tasks.TaskAction
9+
import java.io.File
10+
import java.io.ObjectOutputStream
11+
import java.util.jar.JarFile
12+
13+
/*
14+
The libraries task scans the sketchbook libraries folder for all the libraries
15+
This task stores the resulting information in a file that can be used later to resolve dependencies
16+
*/
17+
abstract class LibrariesTask : DefaultTask() {
18+
19+
@InputFiles
20+
val libraryDirectories: ConfigurableFileCollection = project.files()
21+
22+
@OutputFile
23+
val librariesMetaData: RegularFileProperty = project.objects.fileProperty()
24+
25+
init{
26+
librariesMetaData.convention { project.gradle.gradleUserHomeDir.resolve("common/processing/libraries") }
27+
}
28+
29+
data class Jar(
30+
val path: File,
31+
val classes: List<String>
32+
) : java.io.Serializable
33+
34+
data class Library(
35+
val jars: List<Jar>
36+
) : java.io.Serializable
37+
38+
@TaskAction
39+
fun execute() {
40+
val output = libraryDirectories.flatMap { librariesDirectory ->
41+
if (!librariesDirectory.exists()) {
42+
logger.error("Libraries directory (${librariesDirectory.path}) does not exist. Libraries will not be imported.")
43+
return@flatMap emptyList()
44+
}
45+
val libraries = librariesDirectory
46+
.listFiles { file -> file.isDirectory }
47+
?.map { folder ->
48+
// Find all the jars in the sketchbook
49+
val jars = folder.resolve("library")
50+
.listFiles{ file -> file.extension == "jar" }
51+
?.map{ file ->
52+
53+
// Inside each jar, look for the defined classes
54+
val jar = JarFile(file)
55+
val classes = jar.entries().asSequence()
56+
.filter { entry -> entry.name.endsWith(".class") }
57+
.map { entry -> entry.name }
58+
.map { it.substringBeforeLast('/').replace('/', '.') }
59+
.distinct()
60+
.toList()
61+
62+
// Return a reference to the jar and its classes
63+
return@map Jar(
64+
path = file,
65+
classes = classes
66+
)
67+
}?: emptyList()
68+
69+
// Save the parsed jars and which folder
70+
return@map Library(
71+
jars = jars
72+
)
73+
}?: emptyList()
74+
75+
return@flatMap libraries
76+
}
77+
val meta = ObjectOutputStream(librariesMetaData.get().asFile.outputStream())
78+
meta.writeObject(output)
79+
meta.close()
80+
}
81+
}

0 commit comments

Comments
 (0)