]> Cypherpunks.ru repositories - gocheese.git/commitdiff
Prepare for website v2.2.0
authorSergey Matveev <stargrave@stargrave.org>
Sun, 8 Dec 2019 16:39:29 +0000 (19:39 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Mon, 9 Dec 2019 13:45:04 +0000 (16:45 +0300)
.gitignore
INSTALL
Makefile
PUBKEY.asc [new file with mode: 0644]
VERSION
download.texi [new file with mode: 0644]
go.mod
gocheese.texi
makedist.sh [new file with mode: 0755]
style.css [new file with mode: 0644]
www.mk [new file with mode: 0644]

index 592ed2d2d54cf2a6ccbeefdcb5216ed6b030c233..87d55b6ac6fd51f48d6196207ac16aec505df089 100644 (file)
@@ -1,2 +1,3 @@
 gocheese
 gocheese.info
 gocheese
 gocheese.info
+gocheese.html
diff --git a/INSTALL b/INSTALL
index 843355afcc9fbf7a88354473b387aab07a58b50b..0b69a6c1593beb62c53cc8242c884a32bb007f2b 100644 (file)
--- a/INSTALL
+++ b/INSTALL
@@ -1,23 +1,28 @@
-    # or use https://git.cypherpunks.ru/git/gocheese.git
-    $ git clone --depth 1 --branch v2.1.0 git://git.cypherpunks.ru/gocheese.git
-    $ cd gocheese
-    $ git tag --verify v2.1.0
-    $ make
+Preferable way is to download tarball with the signature from
+website and, for example, run tests with benchmarks:
 
 
-gocheese binary and gocheese.info documentation should be built.
-Although you can also use:
+@verbatim
+$ [fetch|wget] http://gocheese.cypherpunks.ru/gocheese-2.2.0.tar.xz
+$ [fetch|wget] http://gocheese.cypherpunks.ru/gocheese-2.2.0.tar.xz.sig
+$ gpg --verify gocheese-2.2.0.tar.xz.sig gocheese-2.2.0.tar.xz
+$ xz -d < gocheese-2.2.0.tar.xz | tar xf -
+$ make -C gocheese-2.2.0 all test
+@end verbatim
 
 
-    go get go.cypherpunks.ru/gocheese
 
 
-but neither PGP-based authentication is performed, nor documentation build.
+You have to verify downloaded tarballs integrity and authenticity to be
+sure that you retrieved trusted and untampered software. GNU Privacy
+Guard is used for that purpose.
 
 For the very first time it is necessary to get signing public key and
 
 For the very first time it is necessary to get signing public key and
-import it for verifying git's tag. Its fingerprint is:
+import it. It is provided below, but you should check alternative
+resources.
 
 
-    CF60 E89A 5923 1E76 E263 6422 AE1A 8109 E498 57EF
+    pub   rsa2048/0xCD5CD01F55343D88 2019-12-08 [SC]
+          9B27640BA78437EC6D4ACA6CCD5CD01F55343D88
+    uid   GoCheese releases <gocheese@cypherpunks.ru>
 
 
-You can locate it using:
+    Look in PUBKEY.asc file.
 
 
-    $ gpg --auto-key-locate dane --locate-keys stargrave at stargrave dot org
-    $ gpg --auto-key-locate wkd --locate-keys stargrave at stargrave dot org
-    $ gpg --auto-key-locate wkd --locate-keys stargrave at gnupg dot net
+    $ gpg --auto-key-locate dane --locate-keys gocheese at cypherpunks dot ru
+    $ gpg --auto-key-locate wkd --locate-keys gocheese at cypherpunks dot ru
index aa71341ccc08320d0c2a2782a9c72c8d886f70d8..3fdfbd42e8a6c0194fa4553690761849d9e59502 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,13 +1,19 @@
 GO ?= go
 MAKEINFO ?= makeinfo
 
 GO ?= go
 MAKEINFO ?= makeinfo
 
+GOPATH != pwd
 VERSION != cat VERSION
 VERSION != cat VERSION
+
+MOD = go.cypherpunks.ru/gocheese/v2
 LDFLAGS = -X main.Version=$(VERSION)
 
 all: gocheese gocheese.info
 
 LDFLAGS = -X main.Version=$(VERSION)
 
 all: gocheese gocheese.info
 
-gocheese: gocheese.go
-       GOPATH=$(GOPATH) go build -ldflags "$(LDFLAGS)"
+gocheese:
+       GOPATH=$(GOPATH) go build -o gocheese -ldflags "$(LDFLAGS)" $(MOD)
 
 gocheese.info: gocheese.texi
        $(MAKEINFO) -o $@ gocheese.texi
 
 gocheese.info: gocheese.texi
        $(MAKEINFO) -o $@ gocheese.texi
+
+test:
+       GOPATH=$(GOPATH) go test $(MOD)/...
diff --git a/PUBKEY.asc b/PUBKEY.asc
new file mode 100644 (file)
index 0000000..af4caff
--- /dev/null
@@ -0,0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RetvlSaQbFLgy8MkKz
+VA9CnQiz0qdcZN1GXokBswQQAQoAHRYhBO/V3uTUaZUnrXG21nwDpYWOD+SqBQJd
+7kxuAAoJEHwDpYWOD+SqgzEL/1sok8tODe/hAS3KT4O/ooPCT7ezSlfoCv2ezvJa
+sRgtNRtBuB/sxb4KOy+Xz9Z9Ctf/HowpkNeL2x0XPlboL8P5h1P2boShfJCLUFqX
+lrfbvqomKGsii89CWAib/qW+h/gNXg0UOD7nl+RwN7fbvmNwpetQdUYlYHRfjFt+
+10dGI2XluWWzrvEms+F1Jo8wYz/dJw2QZ+8/lE/19blCSYIJoe2CJJ2Pn2A2W2tg
+Y5BGZIWPT5DHisAWHlcBDaSzgXCWJ+/fFN2Zz5vkkQkpvtz1zftUojZXkIbiGdKe
+/YJCg6UeTMrKo26UoJYu9IgoTNvaflOPEbMBBponqBU+mGTy48iWkCJMk+Yh+WaX
+DQPpJ7JdKNR/e6g3uvcdZ4QjbQJ8c+h4meBFabY+KUbccszO9VTiEHBsfeXkt+vI
+4MXM0bfCmHxeScB/iT16b/4vtmU4eRXD838E/JLnXKhErrST8vYiPf+JREVX87Q3
+cl5uH/qEbhY+Fb6EiV2syRAyvA==
+=aDrN
+-----END PGP PUBLIC KEY BLOCK-----
diff --git a/VERSION b/VERSION
index 7ec1d6db40877765247db18e7f9a4e36a0def4ad..ccbccc3dc62631f22ff358ac418e52401ec770b4 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.1.0
+2.2.0
diff --git a/download.texi b/download.texi
new file mode 100644 (file)
index 0000000..d43dd66
--- /dev/null
@@ -0,0 +1,49 @@
+@node Download
+@unnumbered Download
+
+Preferable way is to download tarball with the signature from
+website and, for example, run tests with benchmarks:
+
+@verbatim
+$ [fetch|wget] http://gocheese.cypherpunks.ru/gocheese-2.2.0.tar.xz
+$ [fetch|wget] http://gocheese.cypherpunks.ru/gocheese-2.2.0.tar.xz.sig
+$ gpg --verify gocheese-2.2.0.tar.xz.sig gocheese-2.2.0.tar.xz
+$ xz -d < gocheese-2.2.0.tar.xz | tar xf -
+$ make -C gocheese-2.2.0 all test
+@end verbatim
+
+@multitable {XXXXX} {XXXX-XX-XX} {XXXX KiB} {link sign} {xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx}
+@headitem Version @tab Date @tab Size @tab Tarball @tab SHA256 checksum
+
+@end multitable
+
+You @strong{have to} verify downloaded tarballs integrity and
+authenticity to be sure that you retrieved trusted and untampered
+software. @url{https://www.gnupg.org/, GNU Privacy Guard} is used
+for that purpose.
+
+For the very first time it is necessary to get signing public key and
+import it. It is provided below, but you should check alternative
+resources.
+
+@verbatim
+pub   rsa2048/0xCD5CD01F55343D88 2019-12-08 [SC]
+      9B27640BA78437EC6D4ACA6CCD5CD01F55343D88
+uid   GoCheese releases <gocheese@cypherpunks.ru>
+@end verbatim
+
+@itemize
+
+@item
+@verbatim
+$ gpg --auto-key-locate dane --locate-keys gocheese at cypherpunks dot ru
+$ gpg --auto-key-locate wkd --locate-keys gocheese at cypherpunks dot ru
+@end verbatim
+
+@item
+@verbatiminclude PUBKEY.asc
+
+@end itemize
+
+You can obtain development source code with
+@command{git clone git://git.cypherpunks.ru/gocheese.git}.
diff --git a/go.mod b/go.mod
index a68b743fe9c9a6e6c8604399ff29c21c7edd7b5c..415514c763a2968c024754fc67e89dee13b492f9 100644 (file)
--- a/go.mod
+++ b/go.mod
@@ -1,4 +1,4 @@
-module go.cypherpunks.ru/gocheese
+module go.cypherpunks.ru/gocheese/v2
 
 go 1.12
 
 
 go 1.12
 
index f4668d76ce02d49a7c55c1dc0ebc84def634444e..626c0e37c1611bcc76dc856d4e2c936dc7dd96da 100644 (file)
@@ -2,6 +2,10 @@
 @documentencoding UTF-8
 @settitle GoCheese
 
 @documentencoding UTF-8
 @settitle GoCheese
 
+@copying
+Copyright @copyright{} 2019 @email{stargrave@@stargrave.org, Sergey Matveev}
+@end copying
+
 @node Top
 @top
 
 @node Top
 @top
 
@@ -23,17 +27,17 @@ Initially it was created as a fork of
 but nearly all the code was rewritten. It has huge differences:
 
 @itemize
 but nearly all the code was rewritten. It has huge differences:
 
 @itemize
-@item proxying and caching of missing packages, including GPG signatures
+@item Proxying and caching of missing packages, including GPG signatures
 @item @url{https://pythonwheels.com/, Wheel} uploading support
 @item @url{https://pythonwheels.com/, Wheel} uploading support
-@item integrity check of proxied packages: MD5, SHA256, SHA512, BLAKE2b-256
+@item Integrity check of proxied packages: MD5, SHA256, SHA512, BLAKE2b-256
 @item SHA256 checksums for stored packages
 @item SHA256 checksums for stored packages
-@item verifying of SHA256 checksum for uploaded packages
-@item storing of uploaded GPG signatures
-@item secure Argon2i (or SHA256) stored passwords hashing
-@item no YAML configuration, just command-line arguments
-@item no package overwriting ability (as PyPI does too)
-@item atomic packages store on filesystem
-@item graceful HTTP-server shutdown
+@item Verifying of SHA256 checksum for uploaded packages
+@item Storing of uploaded GPG signatures
+@item Secure Argon2i (or SHA256) stored passwords hashing
+@item No YAML configuration, just command-line arguments
+@item No package overwriting ability (as PyPI does too)
+@item Graceful HTTP-server shutdown
+@item Atomic packages store on filesystem
 @end itemize
 
 Also it contains @file{pyshop2packages.sh} migration script for
 @end itemize
 
 Also it contains @file{pyshop2packages.sh} migration script for
@@ -44,13 +48,20 @@ GoCheese is free software, licenced under
 @url{https://www.gnu.org/licenses/gpl-3.0.html, GNU GPLv3}:
 see the file COPYING for copying conditions.
 
 @url{https://www.gnu.org/licenses/gpl-3.0.html, GNU GPLv3}:
 see the file COPYING for copying conditions.
 
+Please send questions, bug reports and patches to @url{gocheese@@cypherpunks.ru}.
+
+@insertcopying
+
 @menu
 @menu
+* Download::
 * Usage::
 * Password authentication: Passwords.
 * TLS support: TLS.
 * Storage format: Storage.
 @end menu
 
 * Usage::
 * Password authentication: Passwords.
 * TLS support: TLS.
 * Storage format: Storage.
 @end menu
 
+@include download.texi
+
 @node Usage
 @unnumbered Usage
 
 @node Usage
 @unnumbered Usage
 
diff --git a/makedist.sh b/makedist.sh
new file mode 100755 (executable)
index 0000000..d43af83
--- /dev/null
@@ -0,0 +1,98 @@
+#!/bin/sh -ex
+
+cur=$(pwd)
+tmp=$(mktemp -d)
+release=$1
+[ -n "$release" ]
+
+git clone . $tmp/gocheese-$release
+cd $tmp/gocheese-$release
+git checkout v$release
+
+mod_name=$(sed -n 's/^module //p' go.mod)
+crypto_mod_path=$(sed -n 's#^require \(golang.org/x/crypto\) \(.*\)$#\1@\2#p' go.mod)
+mkdir -p src/$mod_name
+mv *.go go.mod go.sum src/$mod_name
+
+mods="
+golang.org/x/crypto
+golang.org/x/net
+"
+for mod in $mods; do
+    mod_path=$(sed -n "s# // indirect## ; s#^  \($mod\) \(.*\)\$#\1@\2#p" src/$mod_name/go.mod)
+    [ -n "$mod_path" ]
+    mkdir -p src/$mod
+    ( cd $GOPATH/pkg/mod/$mod_path ; tar cf - --exclude ".git*" * ) | tar xfC - src/$mod
+    chmod -R +w src/$mod
+done
+
+for mod in golang.org/x/sys; do
+    mod_path=$(sed -n "s#^\($mod\) \(.*\) h1:.*\$#\1@\2#p" src/$mod_name/go.sum | sed /go.mod/d | sort -n -r | sed -n 1p)
+    [ -n "$mod_path" ]
+    mkdir -p src/$mod
+    ( cd $GOPATH/pkg/mod/$mod_path ; tar cf - --exclude ".git*" * ) | tar xfC - src/$mod
+    chmod -R +w src/$mod
+done
+
+cat > $tmp/includes <<EOF
+golang.org/x/crypto/AUTHORS
+golang.org/x/crypto/argon2
+golang.org/x/crypto/blake2b
+golang.org/x/crypto/CONTRIBUTORS
+golang.org/x/crypto/go.mod
+golang.org/x/crypto/go.sum
+golang.org/x/crypto/LICENSE
+golang.org/x/crypto/PATENTS
+golang.org/x/crypto/README.md
+golang.org/x/net/AUTHORS
+golang.org/x/net/CONTRIBUTORS
+golang.org/x/net/go.mod
+golang.org/x/net/go.sum
+golang.org/x/net/LICENSE
+golang.org/x/net/netutil
+golang.org/x/net/PATENTS
+golang.org/x/net/README.md
+golang.org/x/sys/AUTHORS
+golang.org/x/sys/CONTRIBUTORS
+golang.org/x/sys/cpu
+golang.org/x/sys/go.mod
+golang.org/x/sys/LICENSE
+golang.org/x/sys/PATENTS
+golang.org/x/sys/README.md
+EOF
+tar cfCI - src $tmp/includes | tar xfC - $tmp
+rm -fr src/golang.org $tmp/includes
+mv $tmp/golang.org src
+
+cat > download.texi <<EOF
+@node Download
+@unnumbered Download
+You can obtain releases source code prepared tarballs on
+@url{http://gocheese.cypherpunks.ru/}.
+EOF
+make gocheese.info
+
+rm -rf .git .gitignore style.css makedist* www.mk
+
+find . -type d -exec chmod 755 {} \;
+find . -type f -exec chmod 644 {} \;
+chmod +x pyshop2packages.sh
+
+cd ..
+tar cvf gocheese-"$release".tar --uid=0 --gid=0 --numeric-owner gocheese-"$release"
+xz -9 gocheese-"$release".tar
+gpg --detach-sign --sign --local-user CD5CD01F55343D88 gocheese-"$release".tar.xz
+
+tarball=gocheese-"$release".tar.xz
+size=$(( $(stat -f %z $tarball) / 1024 ))
+hash=$(gpg --print-md SHA256 < $tarball)
+release_date=$(date "+%Y-%m-%d")
+
+cat <<EOF
+An entry for documentation:
+@item @ref{Release $release, $release} @tab $release_date @tab $size KiB
+@tab @url{gocheese-${release}.tar.xz, link} @url{gocheese-${release}.tar.xz.sig, sign}
+@tab @code{$hash}
+EOF
+
+mv $tmp/$tarball $tmp/"$tarball".sig $cur/gocheese.html/
diff --git a/style.css b/style.css
new file mode 100644 (file)
index 0000000..0dec0f2
--- /dev/null
+++ b/style.css
@@ -0,0 +1,11 @@
+<style type="text/css"><!--
+body {
+    margin: auto;
+    width: 80em;
+    background-color: #AEBECE;
+}
+h1, h2, h3, h4 { text-align: center }
+h1, h2, h3, h4, strong { color: #900090 }
+pre { background-color: #CCCCCC }
+table, th, td { border: 1px solid black }
+--></style>
diff --git a/www.mk b/www.mk
new file mode 100644 (file)
index 0000000..db7632b
--- /dev/null
+++ b/www.mk
@@ -0,0 +1,17 @@
+MAKEINFO ?= makeinfo
+
+CSS != cat style.css
+
+all: gocheese.html
+
+gocheese.html: *.texi
+       rm -f gocheese.html/*.html
+       $(MAKEINFO) --html \
+               --set-customization-variable CSS_LINES='$(CSS)' \
+               --set-customization-variable SHOW_TITLE=0 \
+               --set-customization-variable USE_ACCESSKEY=0 \
+               --set-customization-variable DATE_IN_HEADER=1 \
+               --set-customization-variable TOP_NODE_UP_URL=index.html \
+               --set-customization-variable CLOSE_QUOTE_SYMBOL=\" \
+               --set-customization-variable OPEN_QUOTE_SYMBOL=\" \
+               -o gocheese.html gocheese.texi