From a4e67474d10b0582383892baac3ba64f5195b0c4 Mon Sep 17 00:00:00 2001 From: tavit ohanian Date: Tue, 29 Jun 2021 03:22:24 -0400 Subject: [PATCH] initial fork --- .gitlab-ci.yml | 35 +++++++++++++++++++++++++++++++++++ go.mod | 2 +- pool.go | 2 +- 3 files changed, 37 insertions(+), 2 deletions(-) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..dfab889 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,35 @@ +stages: + - build + - test + +variables: + BUILD_DIR: "/tmp/$CI_CONCURRENT_PROJECT_ID" + +before_script: + - mkdir -p $BUILD_DIR/src + - cd $BUILD_DIR/src + - if [ -d $CI_PROJECT_DIR ] + - then + - echo "soft link $CI_PROJECT_DIR exists" + - else + - echo "creating soft link $CI_PROJECT_DIR" + - ln -s $CI_PROJECT_DIR + - fi + - cd $CI_PROJECT_DIR + +build: + stage: build + tags: + - testing + script: + - echo $CI_JOB_STAGE + - go build + +test: + stage: test + tags: + - testing + script: + - echo $CI_JOB_STAGE + - go test -cover + coverage: '/coverage: \d+.\d+% of statements/' diff --git a/go.mod b/go.mod index f952aa3..f717932 100644 --- a/go.mod +++ b/go.mod @@ -1,3 +1,3 @@ -module github.com/libp2p/go-buffer-pool +module gitlab.dms3.io/p2p/go-buffer-pool go 1.15 diff --git a/pool.go b/pool.go index d812840..51dbd01 100644 --- a/pool.go +++ b/pool.go @@ -1,7 +1,7 @@ // Package pool provides a sync.Pool equivalent that buckets incoming // requests to one of 32 sub-pools, one for each power of 2, 0-32. // -// import (pool "github.com/libp2p/go-buffer-pool") +// import (pool "gitlab.dms3.io/p2p/go-buffer-pool") // var p pool.BufferPool // // small := make([]byte, 1024) -- GitLab