Building Command Line Applications with Click

  Рет қаралды 153,509

Armin Ronacher

Armin Ronacher

Күн бұрын

Пікірлер: 104
@MoonStruckHorrorsX
@MoonStruckHorrorsX 4 жыл бұрын
I usually can't watch programming tutorials but damn. This guy knows how to keep my attention.
@tcarney57
@tcarney57 4 жыл бұрын
I love the simplicity of using the decorators you've provided. So much easier to use than argparse, and you get the help formatting features, too. Many thanks!
@spaceyfounder5040
@spaceyfounder5040 6 жыл бұрын
I love your tempo! Straight to the problem, fast answers, upgrading the program by tiny steps. Yummy! ✓
@gato_pardo
@gato_pardo 7 жыл бұрын
Great video, quick and to the point!! A pleasure to watch.
@DavideNastri
@DavideNastri 7 жыл бұрын
Great work with Click, Armin! Thanks for taking the extra time in filming also this tutorial :)
@QuintinMassey
@QuintinMassey 3 жыл бұрын
I want more! Thank you for recording this, the amount of examples available for Click are VERY scarce (especially video examples).
@jacquev6
@jacquev6 6 жыл бұрын
Great tutorial, very interesting, thanks! I learned a lot and I'm looking forward to using Click.
@zenahrb8316
@zenahrb8316 4 жыл бұрын
This was fantastic. Also your speed inspiring
@omarcrosby
@omarcrosby 2 жыл бұрын
Thanks for the video, definitely helped get me up to speed with click very quickly!
@vadosware
@vadosware 10 жыл бұрын
Great concise/clear video and guide. Love the tools you make, great work
@MeirGabay
@MeirGabay 4 жыл бұрын
i'm shocked that i have just watched the whole video, you explained it very well, thank you!
@timalive1
@timalive1 3 жыл бұрын
great outline! Thanks! One question, what do you use for your command line. love the info above your cursor.
@maryannsalva3462
@maryannsalva3462 4 жыл бұрын
Wow, this is what i need. Glad I found it! Thank you! 👍👍👍
@mclrk
@mclrk 8 жыл бұрын
I cannot find any documentation on how to use the "entry_points" feature of the setup.py file. Can you please direct me to the api documentation?
@null1023
@null1023 6 жыл бұрын
That's really cool. It looks remarkably clean and easy to work with. a lot of little utilities I've done have kinda nasty argument handling, and this really seems like it'd clean things up
@changyulin47
@changyulin47 4 жыл бұрын
save me hours of reading docs, thank you so much!
@allbuzz
@allbuzz 6 жыл бұрын
This is a real quick help to get started with. Thankyou!!
@entwine
@entwine 10 жыл бұрын
I was thinking to write a cli library in python with routing inspired by flask and then a week ago I discovered that Armin already did it. Thanks!
@arnewiese
@arnewiese 10 жыл бұрын
Would you like to share your settings for vim and the osx terminal? :)
@cztanu
@cztanu 8 жыл бұрын
Great stuff. I should get back into using this library.
@TravisHoglund
@TravisHoglund 8 жыл бұрын
What if you want a sub-command to be "account:login". How would you define that with click?
@TravisHoglund
@TravisHoglund 8 жыл бұрын
Awesome Video, great job.
@alexandrucheltuitor9525
@alexandrucheltuitor9525 4 жыл бұрын
What about if I would like to use normal python params in conjunction with click params ? Let's say that I want to use the same function that I provide click.param, but in another piece of code I call that same function though provide another method (non click method), how could this be achieved ?
@RoamingAdhocrat
@RoamingAdhocrat 4 жыл бұрын
I love this, Arwid! Thanks. I'm new to Python so sorry if this is a daft question: is it possible/sensible to use Click to parse and dispatch commands entered into an Urwid text entry widget? Or would that be using a sledgehammer to hit a mallet to crack a nut?
@YannSchmidt
@YannSchmidt 10 жыл бұрын
Impressive ! I was planning to use docopt but i prefer using click. Much more intuitive :) Thanks
@DGDG0000000
@DGDG0000000 5 жыл бұрын
Thank you for this video. I just follow your way and pip install goes ok. But if i import a module from a package of !y own project directory, i get that, error: no commands supplied. If i do that from inside of a function (who is decorate by click.command), i also get an error and click doesn't works. It is unusable if people can no more import there own packages from there own project directory when they use Click. I think i missed an information... could you tell me ?
@dominicnunes2709
@dominicnunes2709 8 жыл бұрын
Is there anything like this for Ruby?
@davidalexander8786
@davidalexander8786 7 жыл бұрын
thor and commander
@Ucancallmemal
@Ucancallmemal 8 жыл бұрын
please something else like this because this was awesome and useful!
@조성민-y9n
@조성민-y9n 4 жыл бұрын
what's the font you are using?
@JohnnyLeeOthon
@JohnnyLeeOthon 9 жыл бұрын
What kind of shell is that?
@davidrsterry
@davidrsterry 9 жыл бұрын
Great video. I hope you'll make more showing us more tricks with click. How about a series on pipsi as well?
@MamboBean343
@MamboBean343 9 жыл бұрын
+Armin Ronacher What shell do you use? zsh?
@richerite
@richerite Жыл бұрын
Can someone give the python3 version of this example? I get errors when using the make_pass_decorator in py3
@elachichai
@elachichai 7 жыл бұрын
I don't get it. Is cli a keyword? why did we get error??
@malayagr
@malayagr 7 жыл бұрын
In the set-up file, you can see that he writes something like this: entry_points = ''' [console_scripts] hello = hello:cli This basically says that set hello as a command, corresponding to the hello.py script and the command should start execution from the function called cli in the script (hence, entry_points). Since there was no cli() function defined in the hello.py script, we got an error.
@midinerd
@midinerd 6 жыл бұрын
when installing the package with "pip install -e ." It will read setup.py and check in the entry_points=[] info hello_output = hello_codefile:cli is read as: "Create an entrypoint: hello_output.exe #I'm on windows hello_output.exe will consume hello_codefile.py and execute cli()" hello_output.exe won't be created until you run: "pip install -e ." It will be in dist/hello_output.exe In this example case it is: hello.exe is created, reads from hello.py, and runs cli() Also means you can 'install' this and create the hello_output.exe executable once, and then you can edit hello_codefile.py and re-run hello_output.exe to observe changed behavior without needing to rebuild hello_output.exe cheers
@ДаниилПрохоров-ю4й
@ДаниилПрохоров-ю4й 8 жыл бұрын
Wow. Top video!
@abhishekkalia2702
@abhishekkalia2702 7 жыл бұрын
This is the author of the flask framework. Why are the comments so ungrateful ?
@RajKumarSingh-xt1pq
@RajKumarSingh-xt1pq 6 жыл бұрын
why dont you upload complete tutorial series?? it would be of great help dude!
@alice_in_wonderland42
@alice_in_wonderland42 5 жыл бұрын
why can't you read the complete documentation?? it will help you.
@EViL3666
@EViL3666 5 жыл бұрын
@@alice_in_wonderland42 Some people finding video based tutorials easier to follow. I sympathise with the OP, I see potential of Click, but his usage of setuptools is confusing (no, its not something I'm familiar with)
@alice_in_wonderland42
@alice_in_wonderland42 5 жыл бұрын
@@EViL3666 for most of the libraries u don't have any video tutorials, but they have great documentation.
@EViL3666
@EViL3666 5 жыл бұрын
@@alice_in_wonderland42 Very true.
@tcarney57
@tcarney57 4 жыл бұрын
@@EViL3666 I think Armin could have left out the setuptools part. Some people begin a project that way. I'm sure there's an argument for doing so, but I can't be bothered. If you're not going to "ship" the app, I don't see the point.
@KonstantinDorichev
@KonstantinDorichev 2 жыл бұрын
Very helful. Thanks a lot!
@elachichai
@elachichai 7 жыл бұрын
what is your PS1?
@PGhai
@PGhai 2 жыл бұрын
Thanks for creating this video
@bendover4728
@bendover4728 5 жыл бұрын
Beautiful!
@DJ-op6jt
@DJ-op6jt 6 жыл бұрын
Hey thanks, just the info i needed !!
@Mid.G.
@Mid.G. 9 жыл бұрын
Using click right now for the first time and its awesome! So is Flask, so is Jinja, so is whatever you're working on next :D. Quick question -- can you upload your .bashrc somewhere? I'm really digging the prompt.
@ripnlip33
@ripnlip33 5 жыл бұрын
Your zsh config is nice. Could you send me your .zshrc? If not, what's the theme and how did you get the workon "virtualenv"? Thanks for the tutorial
@peteroliver6670
@peteroliver6670 2 жыл бұрын
I just find you now guy amazing tool to use in terminal
@peiquedq
@peiquedq 4 жыл бұрын
Very nice, thank you very much :)
@AndrewRodgers
@AndrewRodgers 5 жыл бұрын
Thanks, somehow click didn't click until watching this.
@jpaldama9963
@jpaldama9963 5 жыл бұрын
Do you have a email of a way I can contact you? python advice? pay?
@arjhuns9072
@arjhuns9072 2 жыл бұрын
If y'all didn't know, he created the library lol
@vatsalaykhobragade
@vatsalaykhobragade 6 жыл бұрын
He created Flask.
@sdelquin
@sdelquin 10 жыл бұрын
Useful lib! Thanks for that. Just offtopic: could you post your .vimrc and $PS1?? They look great!
@steelday
@steelday 10 жыл бұрын
github.com/mitsuhiko/dotfiles
@smprather
@smprather Жыл бұрын
8 years old. How about an update using Python 3 and Poetry?
@shipeng3923
@shipeng3923 10 жыл бұрын
So cool
@elachichai
@elachichai 7 жыл бұрын
looks like you are showing off your vi editor skills than tutor click
@andrewsanchez5895
@andrewsanchez5895 7 жыл бұрын
If he was showing of he wouldn't have quit vim every time he wanted to run a shell command ;) :! hello
@memoriasIT
@memoriasIT 6 жыл бұрын
Andrew Sanchez I didn’t know that, thanks bro
@timetraveller3647
@timetraveller3647 6 жыл бұрын
pretty sure there was much more to learn but you couldn't look past the editor
@smitty1e
@smitty1e 6 жыл бұрын
Spacemacs.org
@scriptingtips596
@scriptingtips596 6 жыл бұрын
It should be taken as a compliment: if you think he is showing that's because you're impressed with his skills :-) But vim wizards do not use their mouse. I'm 0:52secs into the video and the author is already moving his mouse everywhere.
@thestarlightvarietyshow9303
@thestarlightvarietyshow9303 4 жыл бұрын
watched this and was like, wow, he seems like a pretty good programmer. Or perhaps he's just mediocre by most standards and I'm a bad programmer. Later I found out he invented flask-restless and now I feel better about myself :)
@sorvex9
@sorvex9 3 жыл бұрын
Yeah I also felt pretty bad about my programming skills watching this.
@kebabimpaler
@kebabimpaler 4 жыл бұрын
Sold
@jessw4195
@jessw4195 6 жыл бұрын
Great video but slowing down would have been nice. No need to go at the speed of light there.
@lamnguyentrong275
@lamnguyentrong275 4 жыл бұрын
nice, but next time could u speak louder please, the audio kinda small
@lohannasarah5054
@lohannasarah5054 7 жыл бұрын
thanks!!!
@__se7entin__
@__se7entin__ 4 жыл бұрын
Damn are you typing with your mind 😅
@unique1o1-g5h
@unique1o1-g5h 7 жыл бұрын
i thought i was watching this video at 1.5X but it was 1.0X
@elachichai
@elachichai 7 жыл бұрын
do you have something visual to understand calls instead of so much textual explanation? please keep in mind you are not explaining to pros.
@carlfranz6805
@carlfranz6805 2 жыл бұрын
Talks fast, not enough pictures...
@pratsbhatt
@pratsbhatt 8 жыл бұрын
Way to fast.. Are you trying to catch a bus?
@DavideNastri
@DavideNastri 7 жыл бұрын
I think this is the pace of his thinking :) Thank god we can replay it or pause it.
@pawel7318
@pawel7318 7 жыл бұрын
I like the tempo. hint: YT allows you to set different speed of the playback - check the settings
@imxron
@imxron 7 жыл бұрын
too*
@louisburke8927
@louisburke8927 9 жыл бұрын
The sound of your keyboard is extremely annoying.
@JamesOShaughnessy
@JamesOShaughnessy 9 жыл бұрын
Whats click?
@louisburke8927
@louisburke8927 9 жыл бұрын
It's a framework for building command line interfaces
@redstoneisawesome9336
@redstoneisawesome9336 9 жыл бұрын
+Louis Burke It's probably just me, being wierd, but for some reason I like the sound of people typing... Please don't scream at me I'm not trying to sound ignorant, disrespectful etc.
@redstoneisawesome9336
@redstoneisawesome9336 9 жыл бұрын
+James O'Shaughnessy xD( After The sound of your keyboard is extremely annoying
@louisburke8927
@louisburke8927 9 жыл бұрын
No screaming shall be done I just think it's poor from a video editing POV
@hos5759
@hos5759 7 жыл бұрын
You are not a great teacher!! Are you trying to show us how good you are?
@andrewsanchez5895
@andrewsanchez5895 7 жыл бұрын
I thought the video was excellent. A great student will learn even when the teacher doesn't fulfill their desires :)
@fuzzerify
@fuzzerify 7 жыл бұрын
Did you consider you might not be a very good student.
Rye: a Hassle-Free Python Experience (Rye 0.21 Demonstation)
16:42
Armin Ronacher
Рет қаралды 35 М.
7 Essential Command Line Tools (2022)
9:12
Tech Craft
Рет қаралды 225 М.
So Cute 🥰 who is better?
00:15
dednahype
Рет қаралды 19 МЛН
The Best Band 😅 #toshleh #viralshort
00:11
Toshleh
Рет қаралды 22 МЛН
Transforming Code into Beautiful, Idiomatic Python
48:51
Next Day Video
Рет қаралды 1 МЛН
Writing Awesome Command-Line Programs in Python
41:25
EuroPython 2014
Рет қаралды 128 М.
Beginner's Guide to the Bash Terminal
1:14:37
Joe Collins (EzeeLinux)
Рет қаралды 2,3 МЛН
Build AWESOME CLIs With Click in Python
25:12
ArjanCodes
Рет қаралды 48 М.
Let's Make Better Command Line Applications
36:43
Next Day Video
Рет қаралды 10 М.
Amjith Ramanujam   Awesome Command Line Tools   PyCon 2017
28:42
PyCon 2017
Рет қаралды 29 М.