Live data from Hacker News

TTE: Terminal Text Effects

chrisbuilds.github.io

241–250 of 279 posts

Re: TTE: Terminal Text Effects

#241
post #201

I integrated this[1] with my MOTD on ssh login.. :) With random effect each time. 1: https://keeb.dev/static/login.mp4

How do you do that? If possible share the script please..

Anything in your ~/.bashrc or ~/.zshrc gets executed in sequence, so at the bottom of it I have

    /home/keeb/code/projects/login/motd.sh
And the contents of that file is...

    #!/usr/bin/env zsh

    values=("bubbles" "slide" "beams" "rain" "pour" "synthgrid" "unstable" "poop")
    len=${#values[@]}
    index=$(( (RANDOM % (len - 1)) + 1 ))
    selected=${values[$index]}
    cat /home/keeb/code/projects/login/motd | tte $selected

Re: TTE: Terminal Text Effects

#243

I freaking love this library! It reminds me of a time that I don't even know happened when computers seemed like a scifi possibility come true. So happy to see it on the front page. One of the coolest things is not just the ability to pipe cat outputs into it, but that it doubles up as a python library- next time you're making a throw away CLI with print outs and prompts, why not make it insanely jazzy?

It's fun for silly stuff, but I've definitely been on enough slow links that I wouldn't put it in a serious tool. EDIT: Don't get me wrong, I think it's really cool, but I wouldn't use it as a universal hammer.

On the contrary, I am currently scaffolding out the template projects for a new system at $DAYJOB and I'm seriously considering putting it in the CLI tool template.

On the one hand, these tools are going to be used for Serious Business™ but on the other hand... I owe it to 14 year old me. I'll probably add something to allow disabling it with a flag file that can be created with the tool or manually. ¯\_(ツ)_/¯

Re: TTE: Terminal Text Effects

#244
post #166

Earlier quoted context omitted.

"Be specific" sounds like a high-stakes interview, so I'd better answer. :) * SITUATION: Factory reports MVP factory stations for pilot customer "not turning on" for the day, reason unknown. * TASK: Get stations up in time for production line, so startup doesn't go out of business. * ACTION: Determined cause was unexplained networking problem outside our control, and that was triggering some startup time checks. But…

Is it me reading it wrong or are you using two "startup" meanings in sentences very close to each other?

I realized that, and so tried to say "boot" for one of the term senses, but missed an occurrence, which might've made it even more confusing.

Re: TTE: Terminal Text Effects

#246

Earlier quoted context omitted.

It's fun for silly stuff, but I've definitely been on enough slow links that I wouldn't put it in a serious tool. EDIT: Don't get me wrong, I think it's really cool, but I wouldn't use it as a universal hammer.

On the contrary, I am currently scaffolding out the template projects for a new system at $DAYJOB and I'm seriously considering putting it in the CLI tool template. On the one hand, these tools are going to be used for Serious Business™ but on the other hand... I owe it to 14 year old me. I'll probably add something to allow disabling it with a flag file that can be created with the tool or manually. ¯\_(ツ)_/¯

I love this kind of things the first time I see them but I would hate it in a tool used everyday

Re: TTE: Terminal Text Effects

#247

Earlier quoted context omitted.

That needs a binary to run on the remote host for protocol support, doesn't it? I wonder how long that'd take to get transferred and running, over as slow a link as it sounds like this was.

"from a local mirror" does not involve transferring the binary over the slow link.

It isn't perfectly clear even in the detailed description whether any other link was available, but I tend to suspect that if anything faster had been, then it would have been used in preference to the one that actually was.

Re: TTE: Terminal Text Effects

#248

Earlier quoted context omitted.

On the contrary, I am currently scaffolding out the template projects for a new system at $DAYJOB and I'm seriously considering putting it in the CLI tool template. On the one hand, these tools are going to be used for Serious Business™ but on the other hand... I owe it to 14 year old me. I'll probably add something to allow disabling it with a flag file that can be created with the tool or manually. ¯\_(ツ)_/¯

I love this kind of things the first time I see them but I would hate it in a tool used everyday

./myfancytool -disablefx

./myfancytool -showfx

Or have an "on first run only" configuration that disables it for subsequent usage of the tool ¯\_(ツ)_/¯

Re: TTE: Terminal Text Effects

#249
post #233

Earlier quoted context omitted.

The people complaining probably don't have the authority to remove it from the base image they're forced to use, unfortunately.

How serious can your enterprise be if they install cowsay on their base image?

How serious it is, and how seriously the people who make decisions take it, are if not strictly orthogonal then certainly not guaranteed to closely correlate.

Re: TTE: Terminal Text Effects

#250

That's nice, but can we add a feature to terminals that actually understands what it shows and can post-process/augment the data? E.g. when `curl -v` dumped 10k json, the terminal would be able to prettify it right in the terminal. When there's an output with seemingly table data, it would be able to show it as a table with sorting, aggregations and export functionality. If it's code, do some syntax. Logs? - collapse…

I believe what you're looking for is Jq for the json prettifying/manipulation, and nushell for tabular text (not sure about that one, I've only seen it mentioned occasionally). I strongly believe this should not become the job of the terminal, as it makes it all the more complicated and would possibly deter people from writing the kind of specialized, portable tools that are Jq and nushell for instance. At most, I think it should be a job for an ncurses application
Post reply on HN