config | 6 +++--- doc/download.texi | 5 +++++ doc/install.texi | 2 +- doc/news.ru.texi | 12 +++++++++++- doc/news.texi | 12 +++++++++++- makedist.sh | 6 ++++-- src/cfg.go | 8 ++++---- src/cmd/nncp-cfgenc/main.go | 8 ++++---- src/go.mod | 3 ++- src/nncp.go | 2 +- diff --git a/config b/config index f385f2b55ce7718e62266e42bb64dc50f32bb6d87aa7f5cfcdd73d25f09db866..e51a457ca4f9055d71d5e84e35e0b897d5a1d442d0279bea01d20959ae8701e9 100644 --- a/config +++ b/config @@ -9,6 +9,6 @@ CFGPATH=${CFGPATH:-$PREFIX/etc/nncp.hjson} SPOOLPATH=${SPOOLPATH:-/var/spool/nncp} LOGPATH=${LOGPATH:-/var/spool/nncp/log} -BINDIR=${DESTDIR}${PREFIX}/bin -INFODIR=${DESTDIR}${PREFIX}/info -DOCDIR=${DESTDIR}${PREFIX}/share/doc/nncp +BINDIR=${BINDIR:-${DESTDIR}${PREFIX}/bin} +INFODIR=${INFODIR:-${DESTDIR}${PREFIX}/info} +DOCDIR=${DOCDIR:-${DESTDIR}${PREFIX}/share/doc/nncp} diff --git a/doc/download.texi b/doc/download.texi index cfeb70d618c3c5a6366c5cfafbf6680ce1e5221c2dcc056e3daf37ea0790a973..375ce6125cff67cc02d597fbbe3e717cf26e947e290da2eeb31530ac9284e461 100644 --- a/doc/download.texi +++ b/doc/download.texi @@ -19,10 +19,15 @@ @item @code{go.cypherpunks.ru/balloon} @tab GNU LGPLv3 @item @code{golang.org/x/crypto} @tab BSD 3-Clause @item @code{golang.org/x/net} @tab BSD 3-Clause @item @code{golang.org/x/sys} @tab BSD 3-Clause +@item @code{golang.org/x/term} @tab BSD 3-Clause @end multitable @multitable {XXXXX} {XXXX-XX-XX} {XXXX KiB} {link sign} {xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx} @headitem Version @tab Date @tab Size @tab Tarball @tab SHA256 checksum + +@item @ref{Release 5.5.0, 5.5.0} @tab 2021-01-07 @tab 1161 KiB +@tab @url{download/nncp-5.5.0.tar.xz, link} @url{download/nncp-5.5.0.tar.xz.sig, sign} +@tab @code{EF0CBEE1 520BE97D A210794C 172BF444 E6F75DB2 84F5BD05 66919193 326AED77} @item @ref{Release 5.4.1, 5.4.1} @tab 2020-09-28 @tab 1143 KiB @tab @url{download/nncp-5.4.1.tar.xz, link} @url{download/nncp-5.4.1.tar.xz.sig, sign} diff --git a/doc/install.texi b/doc/install.texi index e6225c09229d24fae882ba1916f01ee979ee2974349021cdf877997f9c6ae4b2..3b6a83dc287ede4e67cac74e233b3f0f2a09d1f5c7b9e445088d6f181fd866c8 100644 --- a/doc/install.texi +++ b/doc/install.texi @@ -14,7 +14,7 @@ NNCP should run on any POSIX-compatible operating system. NNCP is written on @url{https://golang.org/, Go} programming language -and you have to install Go compiler 1.10+ version. @command{Make} (BSD +and you have to install Go compiler 1.12+ version. @command{Make} (BSD and GNU versions are fine) is recommended for convenient building. @url{https://www.gnu.org/software/texinfo/, Texinfo} is used for building documentation (although tarballs already include it). diff --git a/doc/news.ru.texi b/doc/news.ru.texi index 5bcc56d8a75353a81054722d013996b00d9be9ed57f68889ed1bedbe43937a06..0b7cb87b36ec397f811008200dab196c4c5f8e89855268b897dabde18fd8f2d1 100644 --- a/doc/news.ru.texi +++ b/doc/news.ru.texi @@ -1,6 +1,16 @@ @node Новости @section Новости +@node Релиз 5.5.1 +@subsection Релиз 5.5.1 +@itemize + +@item +Уважать @env{BINDIR}, @env{INFODIR} и @env{DOCDIR} переменные окружения +в @file{config} во время установки. + +@end itemize + @node Релиз 5.5.0 @subsection Релиз 5.5.0 @itemize @@ -22,7 +32,7 @@ У команд @command{nncp-call}, @command{nncp-caller} и @command{nncp-daemon} появились @option{-autotoss*} опции для запуска tosser после завершения звонка. @item -Обновлены зависимые библиотеки. +Обновлены зависимые библиотеки. Минимальная требуемая версия Go 1.12. @end itemize diff --git a/doc/news.texi b/doc/news.texi index f668fd634aa9d5c00c4820450508cf5beb502775592d9c4810b0dd541b95997d..d3e5f6967c78ff53c58627770884725d8a451ba53289776e2bc0afc21110ea96 100644 --- a/doc/news.texi +++ b/doc/news.texi @@ -3,6 +3,16 @@ @unnumbered News See also this page @ref{Новости, on russian}. +@node Release 5.5.1 +@section Release 5.5.1 +@itemize + +@item +Respect for @env{BINDIR}, @env{INFODIR} and @env{DOCDIR} environment +variables in @file{config} during installation. + +@end itemize + @node Release 5.5.0 @section Release 5.5.0 @itemize @@ -24,7 +34,7 @@ @command{nncp-call}, @command{nncp-caller} and @command{nncp-daemon} commands have @option{-autotoss*} options for running tosser after call is ended. @item -Updated dependencies. +Updated dependencies. Minimal required Go version is 1.12. @end itemize diff --git a/makedist.sh b/makedist.sh index 9691f86241ce58857a471a2e55c699f565d0faffc53b69039b28f1a6ec0c7805..032723c4b67ce46f8d27ec0e63961f33db117b01fd2ebe6bf8858f69b6c8a8d4 100755 --- a/makedist.sh +++ b/makedist.sh @@ -9,6 +9,7 @@ git clone . $tmp/nncp-$release cd $tmp/nncp-$release git checkout v$release redo module-name VERSION +rm -r .redo mod_name=`cat module-name` rm -fr .git @@ -28,6 +29,7 @@ go.cypherpunks.ru/balloon golang.org/x/crypto golang.org/x/net golang.org/x/sys +golang.org/x/term " for mod in $mods; do mod_path=$(sed -n "s# // indirect## ; s#^ \($mod\) \(.*\)\$#\1@\2#p" src/$mod_name/go.mod) @@ -55,7 +57,6 @@ golang.org/x/crypto/PATENTS golang.org/x/crypto/poly1305 golang.org/x/crypto/README.md golang.org/x/crypto/salsa20 -golang.org/x/crypto/ssh/terminal golang.org/x/net/AUTHORS golang.org/x/net/CONTRIBUTORS golang.org/x/net/go.mod @@ -73,6 +74,7 @@ golang.org/x/sys/LICENSE golang.org/x/sys/PATENTS golang.org/x/sys/README.md golang.org/x/sys/unix +golang.org/x/term EOF tar cfCI - src $tmp/includes | tar xfC - $tmp rm -fr src/golang.org $tmp/includes @@ -179,7 +181,7 @@ rm -r doc/.well-known doc/nncp.html/.well-known ######################################################################## -rm -r .redo +rm -r .redo doc/.redo find . -type d -exec chmod 755 {} \; find . -type f -exec chmod 644 {} \; find . -type f -name "*.sh" -exec chmod 755 {} \; diff --git a/src/cfg.go b/src/cfg.go index 184b24dcd6b7da40ee86011f6ce3f758a70721c5d2a66f2cd564608b4bf5b2e3..1d4cd185a7e6f0137c6db602b63e63f300e5af3158b9028c3c0f322499f0fb66 100644 --- a/src/cfg.go +++ b/src/cfg.go @@ -30,7 +30,7 @@ "github.com/gorhill/cronexpr" "github.com/hjson/hjson-go" "golang.org/x/crypto/ed25519" - "golang.org/x/crypto/ssh/terminal" + "golang.org/x/term" ) const ( @@ -107,9 +107,9 @@ type CfgJSON struct { Spool string `json:"spool"` Log string `json:"log"` - Umask string `json:"umask",omitempty` + Umask string `json:"umask,omitempty"` - OmitPrgrs bool `json:"noprogress",omitempty` + OmitPrgrs bool `json:"noprogress,omitempty"` Notify *NotifyJSON `json:"notify,omitempty"` @@ -377,7 +377,7 @@ func CfgParse(data []byte) (*Ctx, error) { var err error if bytes.Compare(data[:8], MagicNNCPBv3[:]) == 0 { os.Stderr.WriteString("Passphrase:") // #nosec G104 - password, err := terminal.ReadPassword(0) + password, err := term.ReadPassword(0) if err != nil { log.Fatalln(err) } diff --git a/src/cmd/nncp-cfgenc/main.go b/src/cmd/nncp-cfgenc/main.go index 70391fa61ce656bc1c748f8984d67ab92747cec0964cd1c4e243d608c9cc193e..739f749c87c28a9427452b0b2f6367593dc161cc723600e6e3251c03e187fe36 100644 --- a/src/cmd/nncp-cfgenc/main.go +++ b/src/cmd/nncp-cfgenc/main.go @@ -30,7 +30,7 @@ xdr "github.com/davecgh/go-xdr/xdr2" "go.cypherpunks.ru/nncp/v5" "golang.org/x/crypto/blake2b" - "golang.org/x/crypto/ssh/terminal" + "golang.org/x/term" ) func usage() { @@ -90,7 +90,7 @@ return } os.Stderr.WriteString("Passphrase:") // #nosec G104 - password, err := terminal.ReadPassword(0) + password, err := term.ReadPassword(0) if err != nil { log.Fatalln(err) } @@ -105,13 +105,13 @@ os.Stdout.Write(cfgRaw) // #nosec G104 return } - password1, err := terminal.ReadPassword(0) + password1, err := term.ReadPassword(0) if err != nil { log.Fatalln(err) } os.Stderr.WriteString("\n") // #nosec G104 os.Stderr.WriteString("Repeat passphrase:") // #nosec G104 - password2, err := terminal.ReadPassword(0) + password2, err := term.ReadPassword(0) if err != nil { log.Fatalln(err) } diff --git a/src/go.mod b/src/go.mod index 83fd586a3242bb4979ac3e34634c04d7f95990b6ad8f6d824202eeb7f1d0d498..264344adb1bb6cf95c87b4e444a7005e552e83745ee411bb6fab80c47b4beecb 100644 --- a/src/go.mod +++ b/src/go.mod @@ -12,7 +12,8 @@ go.cypherpunks.ru/balloon v1.1.1 golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad golang.org/x/net v0.0.0-20201224014010-6772e930b67b golang.org/x/sys v0.0.0-20210105210732-16f7687f5001 + golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1 gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b // indirect ) -go 1.10 +go 1.12 diff --git a/src/nncp.go b/src/nncp.go index c5e0ee15e85cc45799b039c5c435a452a93f2a949588eb83278a133f4e1f43ec..6d480f6502e9bd705c3fa7b5587c2d4d5ce82075220a21226281592b1da362b5 100644 --- a/src/nncp.go +++ b/src/nncp.go @@ -38,7 +38,7 @@ along with this program. If not, see .` ) var ( - Version string = "5.5.0" + Version string = "5.5.1" Base32Codec *base32.Encoding = base32.StdEncoding.WithPadding(base32.NoPadding) )