New Upstream Release - golang-github-riywo-loginshell

Ready changes

Summary

Merged new upstream version: 0.0~git20200815.7d26008 (was: 0.0~git20190610.2ed199a).

Resulting package

Built on 2022-10-13T10:51 (took 1m46s)

The resulting binary packages can be installed (if you have the apt repository enabled) by running one of:

apt install -t fresh-releases golang-github-riywo-loginshell-dev

Lintian Result

Diff

diff --git a/README.md b/README.md
index b1f5956..2e31bb4 100644
--- a/README.md
+++ b/README.md
@@ -6,11 +6,12 @@ A golang library to get the login shell of the current user.
 
 Need PR for the other OS!
 
-- Linux
-- Darwin
 - Plan9
+- Linux
 - OpenBSD
 - FreeBSD
+- Android (termux)
+- Darwin
 - Windows
 
 ## Usage
diff --git a/debian/changelog b/debian/changelog
index 622e855..5416e7f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,9 +1,10 @@
-golang-github-riywo-loginshell (0.0~git20190610.2ed199a-4) UNRELEASED; urgency=low
+golang-github-riywo-loginshell (0.0~git20200815.7d26008-1) UNRELEASED; urgency=low
 
   * Trim trailing whitespace.
   * Set upstream metadata fields: Bug-Database, Bug-Submit.
+  * New upstream snapshot.
 
- -- Debian Janitor <janitor@jelmer.uk>  Fri, 04 Sep 2020 03:54:10 -0000
+ -- Debian Janitor <janitor@jelmer.uk>  Thu, 13 Oct 2022 10:49:49 -0000
 
 golang-github-riywo-loginshell (0.0~git20190610.2ed199a-3) unstable; urgency=medium
 
diff --git a/loginshell.go b/loginshell.go
index b579701..6ef28eb 100644
--- a/loginshell.go
+++ b/loginshell.go
@@ -21,6 +21,8 @@ func Shell() (string, error) {
 		return NixShell()
 	case "freebsd":
 		return NixShell()
+	case "android":
+		return AndroidShell()
 	case "darwin":
 		return DarwinShell()
 	case "windows":
@@ -42,15 +44,6 @@ func Plan9Shell() (string, error) {
 	return "/bin/rc", nil
 }
 
-func WindowsShell() (string, error) {
-	consoleApp := os.Getenv("COMSPEC")
-	if consoleApp == "" {
-		consoleApp = "cmd.exe"
-	}
-
-	return consoleApp, nil
-}
-
 func NixShell() (string, error) {
 	user, err := user.Current()
 	if err != nil {
@@ -66,6 +59,14 @@ func NixShell() (string, error) {
 	return ent[6], nil
 }
 
+func AndroidShell() (string, error) {
+	shell := os.Getenv("SHELL");
+	if shell == "" {
+		return "", errors.New("SHELL not defined in android.")
+	}
+	return shell, nil
+}
+
 func DarwinShell() (string, error) {
 	dir := "Local/Default/Users/" + os.Getenv("USER")
 	out, err := exec.Command("dscl", "localhost", "-read", dir, "UserShell").Output()
@@ -82,3 +83,12 @@ func DarwinShell() (string, error) {
 
 	return shell, nil
 }
+
+func WindowsShell() (string, error) {
+	consoleApp := os.Getenv("COMSPEC")
+	if consoleApp == "" {
+		consoleApp = "cmd.exe"
+	}
+
+	return consoleApp, nil
+}

Debdiff

File lists identical (after any substitutions)

No differences were encountered in the control files

More details

Full run details