Making pybricks better with VS code #1127
MrGibbage
started this conversation in
Show and tell
Replies: 1 comment
-
Thank you! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am using VS code and wrote a task to run my pybricks programs. Feel free to use it if you want.
You will need to edit lines 5 and 12:
"label": "Run on Tim",
and
"Tim",
Both of those refer to the robot name, so replace "Tim" with your robot's name.
There's probably room for improvement in the regex for the problemMatcher. I wish the feedback from the compilers in the terminals gave us more feedback (like column numbers for the error location), but oh well.
And to really take advantage of the VS code tasks, you will want to make a keyboard shortcut (often called "keybindings") to run the task.
Hit ctrl-shift-P, then go to "Preferences: Open Keyboard Shortcuts (JSON)". Paste this in if you want to use ctrl-alt-l, or feel free to come up with your own combination.
The args line needs to match the task label for it to work. Unless your robot is named Tim, you'll probably want to change the args line here.
I hope it helps!
Beta Was this translation helpful? Give feedback.
All reactions