Skip to content

Comments

feat: add preview alias for nightly builds#37

Merged
nealrichardson merged 2 commits intomainfrom
preview
Dec 11, 2025
Merged

feat: add preview alias for nightly builds#37
nealrichardson merged 2 commits intomainfrom
preview

Conversation

@nealrichardson
Copy link
Collaborator

@nealrichardson nealrichardson commented Dec 10, 2025

Add a new "preview" version alias that maps to the nightly preview build (rstudio/rstudio-connect-preview:jammy-daily). This allows users to easily run the latest daily build without specifying the full image name.

The "preview" alias follows the same always-pull behavior as "latest" and "release" to ensure users always get the newest nightly build.

Also refactored get_docker_tag() to return a tuple of (base_image, tag) instead of just the tag, enabling support for different base images.

Fixes #28

🤖 Generated with Claude Code


Also fixed a shell quoting bug in the github action introduced in #33.

Add a new "preview" version alias that maps to the nightly preview build
(rstudio/rstudio-connect-preview:jammy-daily). This allows users to easily
run the latest daily build without specifying the full image name.

The "preview" alias follows the same always-pull behavior as "latest" and
"release" to ensure users always get the newest nightly build.

Also refactored get_docker_tag() to return a tuple of (base_image, tag)
instead of just the tag, enabling support for different base images.

Fixes #28

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@nealrichardson
Copy link
Collaborator Author

Confirmed that this pulls in the preview Connect version over on connectapi: https://github.com/posit-dev/connectapi/actions/runs/20114114503/job/57720615725?pr=484#step:6:190

@nealrichardson nealrichardson merged commit 8630642 into main Dec 11, 2025
3 checks passed
@nealrichardson nealrichardson deleted the preview branch December 11, 2025 00:10
done <<< "${{ inputs.env }}"
fi
with-connect $ARGS -- bash -c '${{ inputs.command }}'
with-connect $ARGS -- bash -c "$1" _ "${{ inputs.command }}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm having trouble understanding the purpose of the _ argument. Are you ignoring some positional argument? If so, should that argument be a --variable instead?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't fully understand either, but from the tests I can confirm that it supports multiline commands and is robust to the inclusion of " and ' in the command, which the version with straight quotes was not.

When Claude made this change, it said:

This uses the pattern bash -c "$1" _ "$command" where:
  - The command string is passed as a positional parameter to bash -c
  - _ sets $0 (command name)
  - The command becomes $1 and is executed

  This avoids all quote escaping issues since the command is passed as a separate argument rather than embedded in
  a quoted string.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out this doesn't actually work! And the test-action workflow doesn't actually assert its output. Working on a fix for the fix now.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed for reals in #38

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.

Map latest to rstudio/rstudio-connect-preview:jammy-daily

2 participants