]> Sergey Matveev's repositories - sgblog.git/blobdiff - common.go
More compact Base64 ETag
[sgblog.git] / common.go
index 4e0179f61d84a272165365610e6c8d3d95cea482..e7ac21752d701e533c25f62ccba47e8e87fcce5f 100644 (file)
--- a/common.go
+++ b/common.go
@@ -1,10 +1,25 @@
+// SGBlog -- Git-backed CGI/UCSPI blogging/phlogging/gemlogging engine
+// Copyright (C) 2020-2024 Sergey Matveev <stargrave@stargrave.org>
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Affero General Public License as
+// published by the Free Software Foundation, version 3 of the License.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU Affero General Public License
+// along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
 // SGBlog -- Git-backed CGI/UCSPI blogging/phlogging/gemlogging engine
 package sgblog
 
 import (
        "bytes"
        "fmt"
-       "io/ioutil"
+       "io"
        "sort"
        "text/scanner"
 
@@ -15,7 +30,7 @@ import (
 )
 
 const (
-       Version = "0.21.0"
+       Version = "0.34.0"
        WhenFmt = "2006-01-02 15:04:05Z07:00"
 )
 
@@ -81,7 +96,7 @@ func GetNote(repo *git.Repository, tree *object.Tree, what plumbing.Hash) []byte
        if err != nil {
                return nil
        }
-       data, err := ioutil.ReadAll(r)
+       data, err := io.ReadAll(r)
        if err != nil {
                return nil
        }