-
Notifications
You must be signed in to change notification settings - Fork 22
[AXON-257] Added {{{username}}} keyword for Jira's custom branch template #315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
[AXON-257] Added {{{username}}} keyword for Jira's custom branch template #315
Conversation
@@ -38,13 +42,24 @@ export const StartWorkSettings: React.FunctionComponent<StartWorkSettings> = ({ | |||
}, [changes, controller]); | |||
|
|||
const getTemplatePreview = useCallback(() => { | |||
const usernameBase = 'trevinavery'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TrevinAvery double checking if you are ok with this :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. I don't mind the credit. Haha.
E.g. <code>{'{{{username}}}/{{{prefix}}}{{{issueKey}}}-{{{summary}}}'}</code> will generate | ||
something of the format:{' '} | ||
<code> | ||
{'trevinavery/feature/VSCODE-1005-allow-users-to-configure-the-way-branch-name-is-co'} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TrevinAvery double checking if you are ok with this :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also fine
is this the same as the bitbucket username? I don't think it is, and I think it would be better to retrieve the username assigned in the BB instance. I know my own BB username is different than my email address. email: jeremy.fiel@company.com |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@marcomura can you clarify my concern with the git user info rather than calling the users api for jira or bb? |
hi @jeremyfiel, I believe that this change should be changed as following:
Unfortunately, I didn't have time to apply the required changes yet. FYI: @TrevinAvery |
What Is This Change?
Addresses #250 .
This change adds the
{{{username}}}
keyword for building the Jira's custom branch template.E.g.:
{{{username}}}/{{{prefix}}}}{{{issuekey}}}-{{{{summary}}}}
The username is retrieved from the 'username' part of the git's
user.email
configuration.This change also fixes the
{{{prefix}}}
not working correctly.How Has This Been Tested?
Basic checks:
npm run lint
npm run test
Advanced checks:
Recommendations: