Top
Best
New

Posted by sdovan1 2 days ago

Show HN: Shittp – Volatile Dotfiles over SSH(github.com)
134 points | 84 commentspage 2
ghostly_s 2 days ago|
People who choose such a noxious name for their project that it actually dissuades people who might otherwise be users think that says something about those prudish users, but it really says something about them.
allarm 1 day ago|
Oh! The horror.
gbraad 1 day ago||
I have been doing something similar for years, especially for login to VMs: sets up an environment of my dotfiles based on a checkout and runs a resumable 'screen' session with tmux. This looks elegant (ephemeral), but I seldom log in to a machine I can't leave my files on as installed.

${HOME} is where your dotfiles are.

qudat 2 days ago||
I have a dotfiles git repo that symlinks my dotfiles. Then I can either pull the repo down on remote machine or rsync. I’m not sure why I would pick this over a git repo with a dotfiles.sh script

https://erock-git-dotfiles.pgs.sh/tree/main/item/dotfiles.sh...

montroser 2 days ago|
This is for when you have to ssh into some machine that's not yours, in order to do debugging or troubleshooting -- and you need your precious dotfiles while you're in there, but it would be not nice to scatter your config and leave it as a surprise for the next person.

This installs into temp dirs and cleans it all up when you disconnect.

Personally, my old-man solution to this problem is different: always roll with defaults even if you don't like them, and don't use aliases. Not for everyone, but I can ssh into any random box and not be flailing about.

Even with OP's neat solution, it's not really going to work when you have to go through a jump box, or have to connect with a serial connection or some enterprise audit loggable ssh wrapper, etc

Y_Y 2 days ago|||
There's definitely something be said for speaking the common tongue, and being able to use the defaults when it's necessary. I have some nice customisations, but make a point of not becoming depwndent on them because I'm so often not in my own environment.

On the other hand, your comment has me wondering if ssh-agent could be abused to drag your config along between jump hosts and enterprise nonsense, like ti does forwarding of keys.

cyanf 2 days ago|||
Why would you want to ssh into a machine that's not yours? That's a violation of the Computer Frauds and Abuse Act, up to 10 years in prison!
montroser 2 days ago|||
I think you're joking, but to clarify -- not personally yours. A misbehaving worker box, an app server in the staging environment, etc. A resource owned by the organization for which you work, where it would not be appropriate for you to customize it to your own liking
otterley 2 days ago|||
When you have permission to do so, it isn’t.
est 2 days ago||
I wonder why are dofiles have to be on remote machines?

e.g. I type an alias, the ssh client expands it on my local machine and send complex commands to remote. Could this be possible?

I suppose a special shell could make it work.

Joker_vD 2 days ago||
> I wonder why are dofiles have to be on remote machines?

Because the processes that use them run on the remote machines.

> I type an alias, the ssh client expands it on my local machine and send complex commands to remote.

This is not how SSH works. It merely takes your keystrokes and sends them to the remote machine, where bash/whatever reads and processes them.

Of course, you can have it work the way you imagine, it's just that it'd require a very special shell on your local machine, and a whole RAT client on the remote machine, which your special shell should be intimately aware about. E.g. TAB-completion of files would involve asking the remote machine to send the dir contents to your shell, and if your alias includes a process substitution... where should that process run?

est 1 day ago||
> the processes that use them run on the remote

Yes but but does the process have to read from a file system dotfile, instead of some data fetched over a ssh connection?

> your alias includes a process substitution

Very valid point. How about a special shell only provides sys calls and process substitution on remote, the rest runs on local client, and communicate via ssh?

I understand this will make client "fat" but it's way more portable.

Joker_vD 1 day ago||
> Yes but but does the process have to read from a file system dotfile, instead of some data fetched over a ssh connection?

Well, no. But if you didn't write that program (e.g. bash or vim), you're stuck with what their actual logic is. Which is "read a file from the filesystem". You can, of course, do something like mounting your local home directory onto the remote's filesystem (hopefully, read-only)... But in the end of the day, there are still two separate machines, and you have to mend the divide somehow, and it'll never be completely pretty, I'm afraid.

> How about a special shell only provides sys calls and process substitution on remote.

Again, as I said, lots of RATs exist, not all of them malicious. But to make "the rest runs on local client" you need to write what essentially will end up a "purely remote-only shell". Essentially, all the parts of bash that manage parsing, user interaction and internal state tracking but without actual process management. Perhaps it's a good idea, actually; but untangling the mess of bash source is not going to be easy.

The current solution of "have a completely normal, standard shell run on the remote and stretch the terminal connection to it over the network" is Good Enough for most of people. Which is not surprising given that that's the environment in which UNIX and its shell were originally implemented.

minitech 2 days ago||
> I suppose a special shell could make it work.

Working on it! :)

Remote machines usually don’t need to know your keystrokes or handle your line editing, either. There’s a lot of latency to cut out, local customization to preserve, and protocol simplification to be had.

neocron 2 days ago||
I don't know, I just use the standard on my machine or on remote. Why bother to customize it all the time when you can't work without the customizations
tensegrist 2 days ago||
time to call the it team at work (on the phone) to ask them to add a new item to the software allowlist
grepfru_it 2 days ago|
Be careful, this will force your defaults over system defaults possibly overriding compliance or security settings. There are a few places I noticed where well-placed malware could hop in etc.

It’s not bad software, it’s also not mature. I’m currently on a phone and on vacation so this is the extent of my review. Maybe I’ll circle back around with some PRs next week

tensegrist 2 days ago|||
i was merely joking about the name apparently being intended to be pronounced in a rather juvenile manner
sdovan1 2 days ago|||
It's not obvious, but the shitt-p is borrowed from an anime character. So it should pronounce like sheet-p: https://ipa-reader.com/?text=%C9%95it%CB%90opi%CB%90
darrenf 2 days ago||
For kitty users, see also https://sw.kovidgoyal.net/kitty/kittens/ssh/
deadbabe 2 days ago||
Why call this Shittp? Is it to imply it’s actually shitty and just a proof of concept or fun project?
throw20251220 2 days ago|
More like shit toilet paper. Name like findtherapist.com
More comments...