Sunday, January 31, 2016

Everything I learned about linux in 60 hours, 1454226440

In the last everything in 24/today post I didn't post anything on getting commands into the actual vim file you are editing. Whell for that you can use :read, so for the date something like:

:read !date


Sun Jan 31 01:49:15 CST 2016

Like so.

I've been busy with packing for the move, and working on some weird software stuff I can't really talk about just yet and smashing against a few API's so none of the good stuff in this post, just more dates like, if you don't want to use my(everyone's) perl one:

perl -e "print(time());"

You can always use the command line:

date +%s

I actually do a lot of stuff with time. And I have an argument and a some awesome knowledge on why Unix Epoch Time is the best time system ever... As well as things about Leap Seconds...Oh dear the things I could talk about   leap seconds.

But what's the big haps your going to see besides some of that stuff. Well I found the Second Edition of Kernighan and Ritchie's C book...so oh my do you have some Classic  C stuff.

But OH DUSTY, WHY NOT C++. Go read jwz's wikipedia page, cause we agree on that wholeheartedly. Not that jwz actually knows me...

WE ARE NOT WORTHY
WE ARE NOT WORTHY
WE ARE NOT WORTHY


I had someone dis me for using perl today, all bragging about javascript and node, and I was like you don't understand I like node, and this conversation happened.


Facebook tier is the two words cut off at the bottom


Anyway for our one liner today I am tempted to talk about httpie, which is a python utility/module that makes everything easier. Sure curl is great, and you should know curl, cause it's classic and it's basic and it's         ubiqutious. But damn if httpie isn't a little sexier with a brighter syntax.


So let's pie this bitch:

http --verify no GET https://mechanicalpinata.com/bullshit X-Auth-Token:shittoken content-type:application/json
~                                                                            


So that's GETting mechanicalpinata.com/bullshit, with a header of content type and an X-Auth-Token, if you are already super comfortable with curl, no worries and skip on. But otherwise, learn commit and do.


No comments: