Skip to content

VS Code Extension which creates buttons in the status bar to open scripts

Notifications You must be signed in to change notification settings

stereochuck/quick-watch

 
 

Repository files navigation

Quick Scripts

quick-scripts

https://marketplace.visualstudio.com/items?itemName=puyanwei.quick-scripts

Add buttons to the status bar to quickly execute scripts!

I found it annoying constantly typing in the terminal or finding the NPM script sidebar button to run my scripts so I created this simple application.

Features

Adding a button

Add a button by opening the command palette (Command + Shift + P) and finding the quick scripts option by typing it in.

1

Once selected, add the script you would like to use. In this example we are using package.json and running a frontend project with storybook, so the script would be yarn run storybook.

2

Name the button to add it to the status bar. Button names are limited to 5 characters.

3

Button now shows up in the status bar as SB. Clicking it will open a new terminal and run the script.

Screenshot 2022-08-29 at 20 02 10

Note that the terminal will always run at the root if your project, so it is recommended you prefix your script with the path to where the script is using it with [path] && [command]. For example if the package.json is in the next folder you would run cd ./next && yarn dev.

After the button is created, you can rollover your mouse to see what the script command is.

Screenshot 2022-09-02 at 18 15 04

Removing a button

Delete a button by opening the command palette (Command + Shift + P) and finding the quick scripts option by typing it in.

4

Then select the button you wish to delete, or delete them all.

5

Once selected, this will reload VS Code and remove the button from the status bar.

Bugs

This is my first VS code extension and I used this project to learn and get the experience of the process.

Feel free to open an issue if you find any bugs or have any suggestions. This is a side project so expanding the features is unlikely, but feel free to fork and submit a PR if you can code it and I'd be happy to review it and add it in 🙏

Socials

Feel free to follow me or if your feeling generous buy me a coffee!

Github Twitter Medium blog Coffee Icon graphic designer

About

VS Code Extension which creates buttons in the status bar to open scripts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 100.0%