diff --git a/app/controllers/crate/settings/new-trusted-publisher.js b/app/controllers/crate/settings/new-trusted-publisher.js index ff2eef1b3c1..2231c9b0534 100644 --- a/app/controllers/crate/settings/new-trusted-publisher.js +++ b/app/controllers/crate/settings/new-trusted-publisher.js @@ -27,6 +27,12 @@ export default class NewTrustedPublisherController extends Controller { return ['GitHub']; } + get repository() { + if (this.repositoryOwner && this.repositoryName) { + return `${this.repositoryOwner}/${this.repositoryName}`; + } + } + saveConfigTask = task(async () => { if (!this.validate()) return; diff --git a/app/templates/crate/settings/index.hbs b/app/templates/crate/settings/index.hbs index 1e797bfa3fc..a495b704fb5 100644 --- a/app/templates/crate/settings/index.hbs +++ b/app/templates/crate/settings/index.hbs @@ -81,8 +81,8 @@ GitHub - Repository: {{config.repository_owner}}/{{config.repository_name}}
- Workflow: {{config.workflow_filename}}
+ Repository: {{config.repository_owner}}/{{config.repository_name}}
+ Workflow: {{config.workflow_filename}}
{{#if config.environment}} Environment: {{config.environment}} {{/if}} diff --git a/app/templates/crate/settings/new-trusted-publisher.hbs b/app/templates/crate/settings/new-trusted-publisher.hbs index d6c993cc9d5..f90e212f02b 100644 --- a/app/templates/crate/settings/new-trusted-publisher.hbs +++ b/app/templates/crate/settings/new-trusted-publisher.hbs @@ -106,7 +106,18 @@ {{else}}
- The filename of the publishing workflow. This file should be present in the .github/workflows/ directory of the repository configured above. For example: release.yml or publish.yml. + The filename of the publishing workflow. This file should be present in the + + {{#if this.repository}} + .github/workflows/ + {{else}} + .github/workflows/ + {{/if}} + + directory of the + {{#if this.repository}}{{this.repository}} {{/if}} + repository{{unless this.repository " configured above"}}. + For example: release.yml or publish.yml.
{{/if}} {{/let}}