Live data from Hacker News

Show HN: Inshellisense – IDE style shell autocomplete

github.com

101–110 of 161 posts

Re: Show HN: Inshellisense – IDE style shell autocomplete

#101

I wish they had written inShellisense in a more efficient programming language than TypeScript. I recall disabling bash_completion.sh on my computer some time ago due to its negative impact on the startup speed of each iTerm2 session and the delay it introduced when using the key for autocompletion. Before I disabled this feature, I consistently experienced delays of over 300ms between triggering autocomplete and rec…

As a user of this project, Typescript is 100% irrelevant, it's compiled to JS and is just a nodejs process and regular javascript at that point. You can go look at what's installed via `npm list -g`, find the path and notice there's not a single Typescript file in the build output. I wish those aboard the TS/JS hate-train knew what they were even complaining about.

>JS and is just a nodejs process and regular javascript at that point

Yes, and that's what people are complaining about. People use the wrod typescript in this thread because, well, it's what shows up on github, but the same argument would come up if it was in pure js.

People have problem with the fact that you are running a nodejs for the terminal enhancement, not what language it uses

Re: Show HN: Inshellisense – IDE style shell autocomplete

#102
post #26

Earlier quoted context omitted.

I feel like I've trashed millions of files I shouldn't have with `rm` and trying to be clever with regular expressions.

I've done this enough times I use `ls` first, then `rm`

alias rm='rm -i'

Re: Show HN: Inshellisense – IDE style shell autocomplete

#103
post #50

ok. can someone explain to me. I've been using ctrl+r for god knows how long and it solves all my shell completion needs. is inshellisense for average users like me or more advanced users?

If you're more used to ctrl+r, you could try hiSHtory (https://github.com/ddworken/hishtory)

Re: Show HN: Inshellisense – IDE style shell autocomplete

#104

Earlier quoted context omitted.

100ms is a long time to wait for each completion suggestion.

Jakob Nielsen says that 0.1 second is about the limit for having the user feel that the system is reacting instantaneously, meaning that no special feedback is necessary except to display the result... https://www.nngroup.com/articles/response-times-3-important-...

In gaming, delay of 100ms is huge enough for anyone besides the most casual players to notice.

Obviously this are different use-cases, but wouldn't be suprised if it was big enough for people to at least notice

Re: Show HN: Inshellisense – IDE style shell autocomplete

#105
post #65
post #51

Earlier quoted context omitted.

You know I googled this immediately after I posted it, and you're absolutely right, but a good chunk of the syntax still kind of looks like regular expressions so I don't think I was too far off!

Regular expressions and glob(7) expressions look superficially similar, but it is mostly an illusion; they both use * and ? as common metacharacters, but both of those characters mean different things in the two systems. Only the [ and ] characters are used more similarly, but even those have their differences. The two syntaxes only have one common function which functions identically in the two systems, but it is in…

To be pedantic: You're conflating the syntax of regular exprssions, with the (computer science) concept. Glob patterns are a kind of very resticted regular pexressions. Ksh extended the glob syntax so it has the full power of regular expressions in the computer science sense - though without all the extensions of modern regular expressions.

Re: Show HN: Inshellisense – IDE style shell autocomplete

#106

Earlier quoted context omitted.

I've done this enough times I use `ls` first, then `rm`

As much as I can, I do a 'mv ... /tmp' instead of 'rm -rf'. It gets the files out of the way, and provides a way out if that's not what I wanted. '/tmp' will eventually be cleaned by the OS so no (prolonged) space worries.

To add to this, I've been a happy user of the trash-cli for forever. Can recommend.

Re: Show HN: Inshellisense – IDE style shell autocomplete

#107

I wish they had written inShellisense in a more efficient programming language than TypeScript. I recall disabling bash_completion.sh on my computer some time ago due to its negative impact on the startup speed of each iTerm2 session and the delay it introduced when using the key for autocompletion. Before I disabled this feature, I consistently experienced delays of over 300ms between triggering autocomplete and rec…

Don’t bring TypeScript into this. It is very possible to write sub 100ms procedures in TS, but an inelegant algorithm will be slow in any language, eventually.

Man, we are doing a CLI autocomplete for duck sake, and You guys want to spin ENTIRE FUCKIN BROWSER for it, and then argue "well, it isn't THAT slow, so what's the problem".

I'm not some extreme purist that thinks everything should be made in C and then hand optimized in assembly, but Jesus, how wasteful can You get before the slightest amount of self awareness starts to kick in.

And for what reason, to save a week of engineering time learning GOlang?

Re: Show HN: Inshellisense – IDE style shell autocomplete

#108
post #16
post #2

The name is terrific.

The fact that it's coming from Microsoft is even crazier, because obviously you know they had to go through clearance - and made it. I half wonder if the author checked the name first, then started coding......

I picture the first slide of the deck breaking the name down "in shell intellisense" and people nodding at the back...

Re: Show HN: Inshellisense – IDE style shell autocomplete

#109
It's pretty cool but still seems a little rough around the edges. My simple test case was to launch into the shell and see if it loaded any of my normal shell configs like highlighting or auto-suggestions (based on my history) but it seems to just be its own shell entirely. It also doesn't seem to play nicely with `zsh` since I tried to do a `..` (which is a common `zsh` alias for "cd .." which got a `zsh:1: permission denied: ..` and then I tried to run `cd ..` it did nothing.

Keen to see how this pans out though!

Re: Show HN: Inshellisense – IDE style shell autocomplete

#110
post #14

Great idea! Also terrifying :) Given how often I accidentally commit the wrong text in vscode, I shudder to think of the damage I could do with this on my shell, hah! What safety measures are there/could there be?

A simple approach might be that if the resulting exit code is not 0 it won't be used to complete in the future.

When you're writing, building, and executing code, I would not expect a 0 exit code every time.
Post reply on HN