Setup a Template-CLI for Quickly Instantiating Projects

  Рет қаралды 8,600

CodeDunks

CodeDunks

Күн бұрын

In this setup, I help set up a template command-line interface to help you quickly instantiate projects. I have received a couple of comments with regards to the template-cli that I use to quickly build my projects so decided to help walk you guys through setting it up for your own local machine. This is a project that has helped me save a lot of time
Original article used: / creating-a-project-gen...
Github project code: github.com/leoroese/template-cli
Timestamps
0:00 Intro
0:35 Project Start
2:00 Eslint and prettier setup
5:11 template cli start
9:34 create directory content
12:10 credit blog post
12:55 finish index.js
14:35 add babel core
15:00 install globally

Пікірлер: 17
@muratasarslan2359
@muratasarslan2359 2 жыл бұрын
Awesome Leo! Your effort on these videos are really of the highest appreciation and helped me a lot. Please continue :-)
@CodeDunks
@CodeDunks 2 жыл бұрын
Thanks, will do!
@j.erlandsson
@j.erlandsson Жыл бұрын
Very well explained. Cheers for this video. I'll definitely use your GH project as base for mine. 👍
@emersonjjsouza
@emersonjjsouza 2 жыл бұрын
Awesome tutorial! Everthing works on my setup serverless-template thanks :)
@danieltkach2330
@danieltkach2330 Жыл бұрын
Awesome stuff!!! Please keep up the good work. You do "different" kind of stuff. I was bored of basic beginner tutorials. Thank you for this.
@CodeDunks
@CodeDunks Жыл бұрын
Thanks Daniel!
@huizhong3713
@huizhong3713 2 жыл бұрын
nice tutorial
@huscachafe
@huscachafe 2 жыл бұрын
Awsome!
@mehdiasadli5329
@mehdiasadli5329 Жыл бұрын
On mac, when i enter "create-my-app" (that is my cli app name) on the terminal it says command not found, and then i tried it with npx, but then it gives me the error that says "/usr/local/bin/create-my-app: bad interpreter: Permission denied"
@ndstephens
@ndstephens 2 жыл бұрын
i'm on a mac and for some reason running "npm install -g" wasn't working for me. i added a " . " at the end to say "this directory" and it then installed "template-cli" in my PATH. so if you're having issues try "npm install -g ."
@CodeDunks
@CodeDunks 2 жыл бұрын
Hmm thats strange, sorry unfortunately I do most of my personal stuff on Windows and WSL2 as I don't have a personal Mac :/. Glad you got it to work though and thanks for letting others know in case they experience the same.
@joemorcullo5928
@joemorcullo5928 9 ай бұрын
tried doing it with "." on the end but I'm still getting "zsh: command not found: template-cli". After the "npm install -g ." all I'm getting is "up to date", do I need to uninstall first?
@amirhosseinmahdioun6450
@amirhosseinmahdioun6450 Жыл бұрын
when I install my cli app, get an error that says: /c/Users/User/AppData/Roaming/npm/alpha-create-app: line 9: C:\Users\User\AppData\Roaming pm//: Is a directory /c/Users/User/AppData/Roaming/npm/alpha-create-app: line 9: exec: C:\Users\User\AppData\Roaming pm//: cannot execute: Is a directory what should I do? may help me please
@dimitrisqq
@dimitrisqq 7 ай бұрын
Hey Leo thanks for the video! I have 2 questions: 1) how does someone changes that "?" to "✅" and I have prepared a template (GitHub repo) with JS/TS, Playwright, GSAP. I want to create a CLI, which actually will "create" a template based on user input: 1. JS or TS? 2. Install GSAP? 3. Install Playwright? The thing is, that I don't know how to create it: from within the CLI or fetch the files based on user input, example jsconfig.json or tsconfig.json with options? Also common files like .prettierrc.json, .eslintrc.json etc.. If I create it from within (for example having a folder "template" with "common", "javascript", "typescript" subfolders and pick the files needed, i'm afraid that It will be very difficult to debug only @ 1 place (I suppose I will have to debug my end-template and then go and "copy" "paste" parts of code inside my CLI's code & templates folder). But if I "fetch" files then the CLI is not actually versioning correctly since it will only fetch the latest files. I'm superconfused...
@ABCshake
@ABCshake 11 ай бұрын
For anyone using this on windows, the shebang line doesn't work. You'll need a bat file to be able to run the cli using a node interpreter.
@riteshgoswami1596
@riteshgoswami1596 Жыл бұрын
can we be get source code from github?
@thebetacoders4738
@thebetacoders4738 2 жыл бұрын
Awesome content,But your thumbnails are not so attractive that's why your channel is not ranked.
Easy Way to Create CLI Scripts with JavaScript and Node
17:39
James Q Quick
Рет қаралды 49 М.
A clash of kindness and indifference #shorts
00:17
Fabiosa Best Lifehacks
Рет қаралды 57 МЛН
How Senior Programmers ACTUALLY Write Code
13:37
Thriving Technologist
Рет қаралды 1,4 МЛН
Former Gangster’s Plot to Kill Billy Graham
7:07
Billy Graham Evangelistic Association
Рет қаралды 404 М.
This CLI Changed How I Start Projects
10:34
Josh tried coding
Рет қаралды 22 М.
What Makes A Good Cli Tool | Prime Explains
4:26
ThePrimeTime
Рет қаралды 59 М.
Automating Tasks with Node CLIs (with Ahmad Awais) - Learn With Jason
1:18:42
Simulating the Evolution of Rock, Paper, Scissors
15:00
Primer
Рет қаралды 403 М.
Top 10 Javascript One Liners YOU MUST KNOW!
14:16
developedbyed
Рет қаралды 192 М.
A clash of kindness and indifference #shorts
00:17
Fabiosa Best Lifehacks
Рет қаралды 57 МЛН