Skip to content

(via ryandens): Fix Windows batch script: use separate quoted tokens for multiple javaag#374

Merged
ryandens merged 1 commit into
ryandens/windows-buildfrom
macroscope/ryandens/windows-build
Jul 6, 2026
Merged

(via ryandens): Fix Windows batch script: use separate quoted tokens for multiple javaag#374
ryandens merged 1 commit into
ryandens/windows-buildfrom
macroscope/ryandens/windows-build

Conversation

@macroscopeapp

@macroscopeapp macroscopeapp Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes Windows batch script generation to correctly handle multiple -javaagent arguments.

Changes

Modified the Fake.write() method to use platform-aware separators when joining multiple javaagent arguments:

  • Windows: Uses " " (close quote, space, open quote) as the separator so each -javaagent option becomes its own quoted token in the batch script
  • Unix: Continues using a simple space separator to keep all options within a single quoted string

This ensures proper argument parsing on Windows where multiple javaagent options were previously being concatenated incorrectly.

Note

Macroscope: Fix It For Me

  • This PR originated from this comment in ✅ add support for Windows #48.
  • Since auto-merge is on, Macroscope will merge this PR after waiting for checks to pass.
  • If you'd rather not wait, you can always merge this yourself but no further action from you is currently needed.
  • You can also @mention Macroscope in this PR to request further changes.

Activity

Currently: Merged by ryandens

Previously
  • Not merged: unstable
  • Waiting on checks
  • Pushed e1367ab

Note

Fix Windows batch script to use separate quoted tokens for multiple -javaagent options

On Windows, multiple -javaagent options in the generated start script were not properly separated, causing launch failures. The fix passes the current Platform to the Fake writer in JavaagentAwareStartScriptGenerator, which then joins -javaagent entries with " " (close-quote, space, open-quote) on Windows so each agent becomes a separately quoted token. Non-Windows behavior (space-separated) is unchanged.

Macroscope summarized d9ac29b.

@ryandens ryandens force-pushed the macroscope/ryandens/windows-build branch from e1367ab to d9ac29b Compare July 6, 2026 05:27
@ryandens ryandens merged commit de5f5d1 into ryandens/windows-build Jul 6, 2026
3 of 4 checks passed
@ryandens ryandens deleted the macroscope/ryandens/windows-build branch July 6, 2026 05:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant