How to develop this plugin?
Hey
I would like to make PR for this plugin but how can I get started? I would just need some basic steps how can I run the development version of this plugin. I did not find anything related to this in the README
Comments (9)
-
-
- changed status to open
-
reporter Okay I did all those steps. When I press the play button I will see this in the terminal:
After that it does not start another vscode window 🤔
Only when I press ctrl + c to cancel the terminal THEN the other vscode window opens. Why this could happen? I am working on macOS Mojave 10.14.6
-
reporter Okay I managed to create PR! https://bitbucket.org/atlassianlabs/atlascode/pull-requests/660/more-useful-commit-timestamp-formatting/diff
So my current workflow is this:
- make some change
- run `yarn devcompile`
- Start debugging from green play button
- wait until compile done
- ctrl + c on the terminal so the new vscode window will open
- verify the changes
- repeat after every change
So it kinda works but it is very painful specially when I have to do the ctrl + c thing
Any tips for that?
-
If you edit the
prelaunchTask
property in theExtension
configuration inlaunch.json
so that it reads"preLaunchTask": "npm: lookAway"
instead of"preLaunchTask": "npm: watch"
it should solve the issue of the development host not launching immediately. It callstsc
with slightly different arguments (configured inpackage.json
). I’m not sure why including--watch
works on some machines but not others. -
reporter Thx @Nick Rundquist ! This helped! Maybe this is worth mention in the README? Or maybe separate HOW-TO-DEVELOP.md?
-
- changed component to Misc
-
Yeah, it’s definitely time to update the README. I’ve added a task for one of us to do that.
-
- changed status to resolved
- Log in to comment
The following instructions will work on Mac and Linux. Windows should be similar but I don’t know the exact command syntax off the top of my head.
After cloning the repository you’ll need to run the following commands
npm install
npm run devcompile
You’ll also need a launch configuration before you can run the extension from within VS Code. If you’re not familiar with setting these up there’s an example file included in the repository at
.vscode/lauch.json.example
. You can just copy this without the example suffix and VS Code will pick it up.cp .vscode/launch.json.example .vscode/launch.json
.Once you’ve done the above you can run the extension from within VS Code by clicking on the Debug and Run icon in the activity bar, selecting “Extension” and clicking “Start Debugging” (the icon that looks like a play button).
After making a change you’ll need to re-run
npm run devcompile
before debugging in VS Code.