Today we are going to take a look at a small command line tool called wgit
which will help you to copy paste one or more files from a Github repository into your local machine.
Why?
The primary reason why I have created this tool is to easily and effectively copy config files, templates, and scripts from one repository to another. I often use this tool to copy eslint configs, git ignore files and so on for my new and old projects.
How?
Let's see how this tool works. Once you enter the wgit
command in your terminal, it will ask for a Github username and the repository name from where to copy the files. Then it will list out all the files, you can then choose multiple files by selecting them and press Enter to copy to your current directory.
It's a very simple tool to use and it got an intuitive user experience with the file chooser prompts.
Install
You can install this package as a global npm module with the following command:
npm install -g wgit
Usage
wgit
You can also use npx to run:
npx wgit
Please give the tool a try and let me know for any issues or improvements you want the tool should be having. The source code for the tool is public and hosted in Github
Happy hacking!
Top comments (0)