From 932508f702c1e072d80d4646c1d7ba769999b344 Mon Sep 17 00:00:00 2001
From: Greg Alexander
Date: Sat, 19 May 2018 17:50:26 -0400
Subject: [PATCH] re-organize preferences into categories
---
NOTES | 1 -
doc/index.html | 70 ++++++++++++++++++++---------------------
res/xml/preferences.xml | 46 +++++++++++++++------------
3 files changed, 61 insertions(+), 56 deletions(-)
diff --git a/NOTES b/NOTES
index 361fba4..b01ff8f 100644
--- a/NOTES
+++ b/NOTES
@@ -646,7 +646,6 @@ So after some internal debate, I decided to do two changes:
I look forward to seeing if anyone complains about it.
-XXX - make preference categories
XXX - test on optimus v
XXX - publish
diff --git a/doc/index.html b/doc/index.html
index fd55971..83da794 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -66,6 +66,13 @@ of these settings to take effect.
Start on Boot
Automatically start the SimpleSSHD service when the phone powers on.
+Start on Open
+Run the SimpleSSHD service whenever the app is launched. The "STOP"
+button will be replaced with a "QUIT" button that stops the service and
+exits the app. This is useful if you want to only run the service when
+you really need it -- start the app to start listening for connections,
+and then click "QUIT" when you are done.
+
Foreground Service
Run the SimpleSSHD service as an Android "foreground service." This
means a notification will be displayed for the service (you might be able
@@ -74,38 +81,10 @@ On newer versions of Android (since Marshmallow), this may also make
SimpleSSHD more responsive if the phone has been in Doze mode. It does
not seem to increase battery consumption much.
-Start on Open
-Run the SimpleSSHD service whenever the app is launched. The "STOP"
-button will be replaced with a "QUIT" button that stops the service and
-exits the app. This is useful if you want to only run the service when
-you really need it -- start the app to start listening for connections,
-and then click "QUIT" when you are done.
-
Port Number
This is the port number that SimpleSSHD will listen on. It must be
greater than 1024 (because SimpleSSHD does not have root).
-SSH Path
-Path for general dropbear files, which now defaults to
-the app-private directory (usually something like
-/data/data/org.galexander.sshd/files).
-Most importantly, this is where
-authorized_keys is found. It is also where host keys wind up
-(they are created on demand), and where temporary files go. This path
-should probably be under /sdcard.
-
-Login Shell
-Path to the command shell. The default Android shell is
-/system/bin/sh, but you may prefer to use the one that comes with
-busybox or whatever. If you set it to the su binary (i.e.,
-/system/xbin/su), then scp, sftp, and rsync will run as root and
-should be able to access files outside of /sdcard. If the name
-of the shell contains "su" in it, instead of putting
-"-" before argv[0] to indicate the login shell,
-SimpleSSHD puts "-" as argv[1]. That is, a regular
-login shell would be invoked as "-sh", but su will be invoked as
-"su -".
-
Buffer hack for rsync+SuperSU
A bug in SuperSU interacts with an infelicity in rsync to cause an
occasional deadlock. This is a real pain because I use SuperSU+rsync
@@ -115,12 +94,6 @@ should be enabled if you use rsync with SuperSU. It adds a miniscule
overhead to rsync, but isn't harmful even if you aren't using
SuperSU.
-Home Directory
-The login shell's home directory, which also defaults
-to the app-private directory.
-This is where your ssh session starts out, and is where .profile
-will be found if it is present.
-
Extra Commandline
You can specify additional commandline options for dropbear server.
The options which are hardcoded are:
@@ -136,6 +109,33 @@ A common use would be "ENV=/sdcard/ssh/.profile", if your device has a
build of mksh that does not execute a .profile
automatically.
+SSH Path
+Path for general dropbear files, which now defaults to
+the app-private directory (usually something like
+/data/data/org.galexander.sshd/files).
+Most importantly, this is where
+authorized_keys is found. It is also where host keys wind up
+(they are created on demand), and where temporary files go. This path
+should probably be under /sdcard.
+
+Home Directory
+The login shell's home directory, which also defaults
+to the app-private directory.
+This is where your ssh session starts out, and is where .profile
+will be found if it is present.
+
+Login Shell
+Path to the command shell. The default Android shell is
+/system/bin/sh, but you may prefer to use the one that comes with
+busybox or whatever. If you set it to the su binary (i.e.,
+/system/xbin/su), then scp, sftp, and rsync will run as root and
+should be able to access files outside of /sdcard. If the name
+of the shell contains "su" in it, instead of putting
+"-" before argv[0] to indicate the login shell,
+SimpleSSHD puts "-" as argv[1]. That is, a regular
+login shell would be invoked as "-sh", but su will be invoked as
+"su -".
+
Frequently Asked Questions
@@ -171,7 +171,7 @@ harmless.
- 2018/05/19 Version 19: Use the app-private directory by
-default on new installs for the SSH/home dir.
+default on new installs for the SSH/home dir. Organize settings.
- 2018/05/16 Version 18: Use correct idiom for su as a
login shell (so busybox su can work). Add environment variables
to settings.
diff --git a/res/xml/preferences.xml b/res/xml/preferences.xml
index 1fa3a92..3b3e7c5 100644
--- a/res/xml/preferences.xml
+++ b/res/xml/preferences.xml
@@ -1,44 +1,32 @@
+
-
+
+
+
-
-
-
+
+
+
+
+
+