Repository navigation
Keep Code-node JavaScript only in src/*.js, filled in at publish - #6
Merged
Merged
Conversation
…JSON Each Code node's JavaScript now lives in its own file under src/, so a pull request shows a code change as ordinary lines of JavaScript. make build writes the code back into the workflow JSON, make extract seeds src/ from the JSON, and a CI check fails a pull request whose JSON and src/ disagree. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AEavKGR3wFFUQXR9W16mSQ
Each Code node's jsCode in the committed workflow JSON is now a one-line comment naming its src/ file, so a code change touches only the .js file. update-workflow.sh fills the code in before uploading, a merge that changes only src/ publishes the workflows it touches, make build writes filled-in workflows to dist/, and the CI check fails when a Code node holds code or names a missing file, or a src/ file is unused. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AEavKGR3wFFUQXR9W16mSQ
…base branch A new preview job builds the workflows publishing would send from the pull request and from its base branch, and lists each one as identical or names what changed, on the run's summary page. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AEavKGR3wFFUQXR9W16mSQ
jeffabailey
approved these changes
Oct 28, 2026
rrrutledge
marked this pull request as ready for review
October 30, 2026 00:44
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes
Before, each Code node's JavaScript sat inside the workflow JSON as one long escaped string, so a pull request showed a logic change as a single unreadable JSON line.
Now each Code node's JavaScript lives only in its own file under
src/, one folder per workflow and one file per node, and a pull request shows a code change as ordinary lines of JavaScript.In the committed workflow JSON, each Code node's code is a one-line comment naming its file under
src/.Publishing fills the real code in from that file before uploading, both for the automatic publish on merge and for a manual publish.
A merge that changes only a
.jsfile publishes the workflow that uses it.A new GitHub Action, the source-file check, fails a pull request when a Code node holds real code instead of naming a file, when a Code node names a file that doesn't exist, or when a file under
src/belongs to no Code node.make buildwrites every workflow with its code filled in todist/, for importing into n8n by hand, andmake extractturns a workflow exported from the n8n editor back into a one-line comment per node plus itssrc/files.USAGE.mdgains a section on changing a Code node: edit its file undersrc/, and runmake extractafter bringing in a workflow exported from the n8n editor.Publishing sends n8n exactly what it runs today.
How it was verified
Each check below ran against this branch.
previewjob builds the workflows from both the pull request andmainand lists each as identical or names what changed; on this pull request, its run summary lists all 7 as identical.main. The built workflows indist/are byte-for-byte identical to every workflow JSON file onmain..jsfile, the publish step picks the workflow that uses it, alongside any changed workflow JSON.make extracton that pasted export restored the same one-line comments and leftsrc/unchanged.src/files, and the copy deleted.Two of them carry credentials the API key has no access to, so their copies were created with credential references removed.
🤖 Generated with Claude Code
https://claude.ai/code/session_01AEavKGR3wFFUQXR9W16mSQ