Skip to content
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

Master or Main #134

Closed
elcortez opened this issue Oct 16, 2022 · 5 comments
Closed

Master or Main #134

elcortez opened this issue Oct 16, 2022 · 5 comments

Comments

@elcortez
Copy link

elcortez commented Oct 16, 2022

Hello, I'm using this great VS Code extension in order to open the specific file at the specific line in the master or main branch (basically what Atom does when you type CMD+MAJ+P & type "Blame")

Per your instructions, I've managed to make the extension open it with this commit url
${tool.protocol}//${gitorigin.hostname}${gitorigin.port}/${gitorigin.path}/blame/master/${file.path}#L${file.line}

However, I had to write "master" in plain text, for I don't see this option in the instructions, therefore it does not work on repositories that have a "main" branch instead of "master".
It would be really AWESOME if you could make it work ! <3

@Sertion
Copy link
Owner

Sertion commented Oct 16, 2022

Hey Pierre! Thank you for the feature request.

That looks like something that could be added to the token generator.

If you want to give it a go I accept pull requests or I will get to it when I have the time.

@elcortez
Copy link
Author

Hello, thanks for your answer, I would love to try, but I'm kind of a newbie in typescript.
Can you point me to some link where I can learn how to properly test the app or maybe give me a command to run on my terminal to run the tests ?

@Sertion
Copy link
Owner

Sertion commented Oct 22, 2022

If you use vscode as your editor you should be able to run Extension and Test Extension from the Run and Debug menu in the sidebar. Here is an example of some tests for the token generator with some (unfortunately needed) mocking.

To get it up and running all you need is to fork the repository, clone it and run npm install. If you want to check linting before committing you can run npm run lint.

@Sertion
Copy link
Owner

Sertion commented Apr 8, 2023

I had some time over the Easter break and built this. It will be part of 10.2.0. The token is called ${project.defaultbranch}

@Sertion Sertion closed this as completed Apr 8, 2023
@elcortez
Copy link
Author

elcortez commented May 2, 2023

Ohh woaw, thanks a lot ! that's amazing 🙏 👍 ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants