From bb879130cf8333a3dae8515438d925bcf1a75c40 Mon Sep 17 00:00:00 2001 From: nathansmith Date: Sun, 27 Apr 2025 08:04:39 -0600 Subject: Added more spaceFM stuff --- linux_room.html | 57 +++++++++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 49 insertions(+), 8 deletions(-) (limited to 'linux_room.html') diff --git a/linux_room.html b/linux_room.html index 2039390..59595c4 100644 --- a/linux_room.html +++ b/linux_room.html @@ -196,20 +196,61 @@ table {

- +

SpaceFM

For the longest time I just used thunar because its decent and default in xfce though I decided - to give spacefm a try as of writing this. I might got annoyed of it in a week and ditch it or + to give spaceFM a try as of writing this. I might got annoyed of it in a week and ditch it or end up really liking it. These kinds of things tend to go either way for me. I will either - fucking hate it or wonder how I ever lived without it. -

- I am fucking around with udisks2/udiskie and udevil to see what works better for my uses. - To get encrypted partitions working I add udiskie as a startup app in xfce to handle that - shit. Spacefm makes encrypted partitions a pain in the ass but its really configurable so - with enough hacks you can get spacefm to do anything. Thats the magic of spacefm. + fucking hate it or wonder how I ever lived without it.
+ Update: After using it for a little bit I really dig it and never want to go back. +

+ +

Encrypted partitions/the few things udevil doesnt support yet in spaceFM

+

+ SpaceFM doesnt support encrypted partitions by default but lucky for us its very customizable. + To get encrypted disks working I use udisks2 and udiskie. +

+ + +

sftp

+

+ Spacefm uses sshfs for sftp support. Once you install it you will be ready to rock. Though + for my use case I need symlink support. sshfs needs to have the option -o follow_symlinks + To support symlinks. To add the option go to Devices->Settings->Protocol Handlers->ssh and change the + mount option to:
+ + #!/bin/bash +

+ [[ -n "$fm_url_user" ]] && fm_url_user="${fm_url_user}@"
+ [[ -z "$fm_url_port" ]] && fm_url_port=22
+ echo ">>> sshfs -o follow_symlinks -p $fm_url_port $fm_url_user$fm_url_host:$fm_url_path %a"
+ echo
+ # Run sshfs through nohup to prevent disconnect on terminal close
+ sshtmp="$(mktemp --tmpdir spacefm-ssh-output-XXXXXXXX.tmp)" || exit 1
+ nohup sshfs -o follow_symlinks -p $fm_url_port $fm_url_user$fm_url_host:$fm_url_path %a &> "$sshtmp"
+ err=$?
+ [[ -e "$sshtmp" ]] && cat "$sshtmp" ; rm -f "$sshtmp"
+ [[ $err -eq 0 ]] # set error status
+

+ # Alternate Method - if enabled, disable nohup line above and
+ # uncheck Run In Terminal
+ # # Run sshfs in a terminal without SpaceFM task. sshfs disconnects when the
+ # # terminal is closed
+ # spacefm -s run-task cmd --terminal "echo 'Connecting to $fm_url'; echo; sshfs -p $fm_url_port $fm_url_user$fm_url_host:$fm_url_path %a; if [ $? -ne 0 ]; then echo; echo '[ Finished ] Press Enter to close'; else echo; echo 'Press Enter to close (closing this window may unmount sshfs)'; fi; read" & sleep 1
+

-- cgit v1.2.3