Skip to content

Conversation

@sergeibbb
Copy link
Member

@sergeibbb sergeibbb commented Feb 14, 2025

Description

fixes #3218

Checklist

  • I have followed the guidelines in the Contributing document
  • My changes follow the coding style of this project
  • My changes build without any errors or warnings
  • My changes have been formatted and linted
  • My changes include any required corresponding changes to the documentation (including CHANGELOG.md and README.md)
  • My changes have been rebased and squashed to the minimal number (typically 1) of relevant commits
  • My changes have a descriptive commit message with a short title, including a Fixes $XXX - or Closes #XXX - prefix to auto-close the issue that your PR addresses

@sergeibbb sergeibbb requested review from d13 and eamodio February 14, 2025 17:39
@sergeibbb sergeibbb marked this pull request as draft February 26, 2025 15:14
@sergeibbb sergeibbb self-assigned this Feb 26, 2025

protected override splitPath(): [string, string] {
if (this.path.startsWith('scm/')) {
const path = this.path.replace('scm/', '');
Copy link
Member Author

@sergeibbb sergeibbb Mar 3, 2025

Choose a reason for hiding this comment

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

@ericf-axosoft , @axosoft-ramint

const path = this.path.replace('scm/', '');

The biggest problem here is if project name is scm. Can I assume that normally repo path can be either org/repo, where repo part cannot contain slashes?

I'm trying to create a repo name with slashes and Bitbucket replaces it with dashes:
image

Therefore I can check if the path is started with scm/ and look for the second /. If the second / does not exist, then scm is just a project name.

Agree?

@sergeibbb sergeibbb force-pushed the bug/3218-bitbucket-scm-in-path-fix branch from f292bd0 to ed339b4 Compare March 5, 2025 09:44
@sergeibbb sergeibbb marked this pull request as ready for review March 5, 2025 09:46
@sergeibbb sergeibbb requested review from d13 and eamodio and removed request for d13 and eamodio March 5, 2025 09:46
@sergeibbb sergeibbb force-pushed the bug/3218-bitbucket-scm-in-path-fix branch from ed339b4 to 0dcd852 Compare March 5, 2025 12:56
@sergeibbb sergeibbb force-pushed the bug/3218-bitbucket-scm-in-path-fix branch from 0dcd852 to 6b06bd3 Compare March 6, 2025 12:09
@sergeibbb sergeibbb merged commit f18c6b6 into main Mar 6, 2025
2 checks passed
@sergeibbb sergeibbb deleted the bug/3218-bitbucket-scm-in-path-fix branch March 6, 2025 12:09
saeedzaha pushed a commit to saeedzaha/vscode-gitlens that referenced this pull request Apr 28, 2025
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.

Bitbucket Server remote - "scm/" path prefix not removed, possible regression from #767?

2 participants