From fe58f6e648f1023900ded3d4babfbe28344057fe Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 12:26:36 -0300 Subject: [PATCH 01/34] Not process only doc PR Signed-off-by: munapower --- .github/workflows/test.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 77725dc61..efc867402 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -31,6 +31,8 @@ jobs: filters: | docker: - 'utils/docker/**' + notdocumentation: + - !'*.md' - name: build dev image if: steps.filter.outputs.docker == 'true' @@ -41,7 +43,7 @@ jobs: make -C utils/docker build build-dev - name: fetch dev image - if: steps.filter.outputs.docker == 'false' + if: steps.filter.outputs.docker == 'false' && steps.filter.outputs.notdocumentation == 'true' env: DOCKER_QUIET_BUILD: 1 run: | @@ -49,6 +51,7 @@ jobs: make -C utils/docker pull pull-dev - name: run make inside dev container + if: steps.filter.outputs.notdocumentation == 'true' env: DOCKER_DEV_CI_MODE: 1 DOCKER_QUIET_BUILD: 1 From 4d622edc6a6a80b3516d7626650b458cd4f1eb73 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 13:01:35 -0300 Subject: [PATCH 02/34] Update paths filter version Signed-off-by: munapower --- .github/workflows/test.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index efc867402..dd455ae2e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -25,7 +25,7 @@ jobs: with: submodules: 'recursive' - - uses: dorny/paths-filter@v2 + - uses: dorny/paths-filter@v3 id: filter with: filters: | @@ -33,7 +33,6 @@ jobs: - 'utils/docker/**' notdocumentation: - !'*.md' - - name: build dev image if: steps.filter.outputs.docker == 'true' env: From a39da60d572d8e3a0616fe471c3a9f86fa617e1c Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 14:52:42 -0300 Subject: [PATCH 03/34] Update paths filter pattern Signed-off-by: munapower --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index dd455ae2e..6c029b69e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,7 @@ jobs: docker: - 'utils/docker/**' notdocumentation: - - !'*.md' + - '!(*.md)' - name: build dev image if: steps.filter.outputs.docker == 'true' env: From 4eb82e185c82e4debad284b2afccb0c53bc65dfa Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 14:57:30 -0300 Subject: [PATCH 04/34] testing github action Signed-off-by: munapower --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 4929010d0..37cd743b6 100644 --- a/README.md +++ b/README.md @@ -704,7 +704,6 @@ repository is prototype code and not intended for production use. ## Initial Committers - - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From f58f5b01ceecf01fa1d8981586840d9169f0afb2 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 15:15:22 -0300 Subject: [PATCH 05/34] Add paths filter base Signed-off-by: munapower --- .github/workflows/test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6c029b69e..d0de6d647 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,8 @@ jobs: docker: - 'utils/docker/**' notdocumentation: - - '!(*.md)' + - '!(**/*.md)' + base: 'main' - name: build dev image if: steps.filter.outputs.docker == 'true' env: From 74f26b0965e5b727ae8ff65526848c816d84abf1 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 15:35:49 -0300 Subject: [PATCH 06/34] testing github action take 2 Signed-off-by: munapower --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 37cd743b6..4929010d0 100644 --- a/README.md +++ b/README.md @@ -704,6 +704,7 @@ repository is prototype code and not intended for production use. ## Initial Committers + - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From bad0ecef556111dedfcb6a34e838a9a4e6807028 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 16:01:15 -0300 Subject: [PATCH 07/34] testing github action take 3 Signed-off-by: munapower --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 4929010d0..2f28574bb 100644 --- a/README.md +++ b/README.md @@ -705,6 +705,9 @@ repository is prototype code and not intended for production use. ## Initial Committers + + + - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From 1ce2a3c0b705bdd4e698be5b1249863e25ce44fb Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 16:33:30 -0300 Subject: [PATCH 08/34] adding workflows to not process Signed-off-by: munapower --- .github/workflows/test.yml | 4 ++-- README.md | 3 --- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d0de6d647..c4c22204d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,7 @@ jobs: docker: - 'utils/docker/**' notdocumentation: - - '!(**/*.md)' + - '!([.github/workflows/**,**/*.md)' base: 'main' - name: build dev image if: steps.filter.outputs.docker == 'true' @@ -65,7 +65,7 @@ jobs: # continue only if we push to main and rebuild docker images # - name: Login to the ${{ env.DOCKER_REGISTRY }} Container Registry - if: env.PUSH_TO_MAIN == 'true' && steps.filter.outputs.docker == 'true' + if: env.PUSH_TO_MAIN == 'true' && steps.filter.outputs.docker == 'true' uses: docker/login-action@v2 with: registry: ${{ env.DOCKER_REGISTRY }} diff --git a/README.md b/README.md index 2f28574bb..4929010d0 100644 --- a/README.md +++ b/README.md @@ -705,9 +705,6 @@ repository is prototype code and not intended for production use. ## Initial Committers - - - - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From 20e6e85d06a55f23c682bc4ace7d178b3f61d109 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 16:41:15 -0300 Subject: [PATCH 09/34] modifying syntax Signed-off-by: munapower --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index c4c22204d..09af63b78 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,7 @@ jobs: docker: - 'utils/docker/**' notdocumentation: - - '!([.github/workflows/**,**/*.md)' + - '!(['.github/workflows/**','**/*.md'])' base: 'main' - name: build dev image if: steps.filter.outputs.docker == 'true' From 18b3e02909a7d0a526c04ab250542626c8951ca7 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 16:49:01 -0300 Subject: [PATCH 10/34] modifying syntax Signed-off-by: munapower --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 09af63b78..28fd970ec 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,7 @@ jobs: docker: - 'utils/docker/**' notdocumentation: - - '!(['.github/workflows/**','**/*.md'])' + - '!(['?github/workflows/**','**/*.md'])' base: 'main' - name: build dev image if: steps.filter.outputs.docker == 'true' From f746d4db8109b6c48cf09f4930ad1759e1f7e454 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 16:50:29 -0300 Subject: [PATCH 11/34] modifying syntax Signed-off-by: munapower --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 28fd970ec..1f3575301 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -32,7 +32,7 @@ jobs: docker: - 'utils/docker/**' notdocumentation: - - '!(['?github/workflows/**','**/*.md'])' + - '!([?github/workflows/**,**/*.md])' base: 'main' - name: build dev image if: steps.filter.outputs.docker == 'true' From 0cdbc8e3ead90fa10f1438f7a01dad3766ea114e Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 29 Jan 2024 16:54:47 -0300 Subject: [PATCH 12/34] testing with echo.go Signed-off-by: munapower --- samples/chaincode/echo-go/chaincode/echo.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index f6f826dac..04ce4345c 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -2,7 +2,7 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 -*/ +test*/ package chaincode From bb0a3e412da419777dafabcde8c52683d8c6e61e Mon Sep 17 00:00:00 2001 From: munapower Date: Wed, 31 Jan 2024 10:39:09 -0300 Subject: [PATCH 13/34] adding filters for actions Signed-off-by: munapower --- .github/workflows/test.yml | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 1f3575301..a068b9a07 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,7 +3,15 @@ # name: FPC test -on: [push, pull_request] +on: + push: + paths: + - '!**.md' + - '!./github/workflows/**' + pull_request: + paths: + - '!**.md' + - '!./github/workflows/**' env: DOCKER_REGISTRY: 'ghcr.io' @@ -31,9 +39,11 @@ jobs: filters: | docker: - 'utils/docker/**' - notdocumentation: - - '!([?github/workflows/**,**/*.md])' - base: 'main' +# documentation: +# - '**.md' +# base: 'main' +# - name: if docu change then go to end + - name: build dev image if: steps.filter.outputs.docker == 'true' env: @@ -43,7 +53,8 @@ jobs: make -C utils/docker build build-dev - name: fetch dev image - if: steps.filter.outputs.docker == 'false' && steps.filter.outputs.notdocumentation == 'true' + if: steps.filter.outputs.docker == 'false' + # && steps.filter.outputs.notdocumentation == 'true' env: DOCKER_QUIET_BUILD: 1 run: | @@ -51,7 +62,7 @@ jobs: make -C utils/docker pull pull-dev - name: run make inside dev container - if: steps.filter.outputs.notdocumentation == 'true' + # if: steps.filter.outputs.notdocumentation == 'true' env: DOCKER_DEV_CI_MODE: 1 DOCKER_QUIET_BUILD: 1 From 18dc6432663b7c99d6179beb52c5f704b6a9564c Mon Sep 17 00:00:00 2001 From: munapower Date: Wed, 31 Jan 2024 10:46:41 -0300 Subject: [PATCH 14/34] testing with echo.gov2 Signed-off-by: munapower --- samples/chaincode/echo-go/chaincode/echo.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index 04ce4345c..04d0e5b17 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -2,7 +2,8 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 -test*/ +test +test2*/ package chaincode From 7e25bc9835457234c3dc0679f48a1d53af764b09 Mon Sep 17 00:00:00 2001 From: munapower Date: Wed, 31 Jan 2024 11:02:02 -0300 Subject: [PATCH 15/34] adding paths ignore for actions Signed-off-by: munapower --- .github/workflows/test.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a068b9a07..62d08de9e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -5,13 +5,13 @@ name: FPC test on: push: - paths: - - '!**.md' - - '!./github/workflows/**' + paths-ignore: + - '**.md' + - '.github/workflows/**' pull_request: - paths: - - '!**.md' - - '!./github/workflows/**' + paths-ignore: + - '**.md' + - '.github/workflows/**' env: DOCKER_REGISTRY: 'ghcr.io' From 59f1f7bf7077217bc72a39ba8b717b7c93502429 Mon Sep 17 00:00:00 2001 From: munapower Date: Wed, 31 Jan 2024 11:03:27 -0300 Subject: [PATCH 16/34] testing with echo.gov3 Signed-off-by: munapower --- samples/chaincode/echo-go/chaincode/echo.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index 04d0e5b17..f204e7669 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -3,7 +3,8 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 test -test2*/ +test2 +test3*/ package chaincode From ffdab4184684dd54ad7454cd096f48fc1fbeb547 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 16:57:55 -0300 Subject: [PATCH 17/34] improving workflow Signed-off-by: munapower --- .github/workflows/documentation.yml | 29 +++++++++++++++++++++++++++++ .github/workflows/test.yml | 6 +----- 2 files changed, 30 insertions(+), 5 deletions(-) create mode 100644 .github/workflows/documentation.yml diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml new file mode 100644 index 000000000..c31dfa420 --- /dev/null +++ b/.github/workflows/documentation.yml @@ -0,0 +1,29 @@ +# +# SPDX-License-Identifier: Apache-2.0 +# + +name: Update Documentation +on: + push: + paths: + - '**.md' + paths-ignore: + - '!**.md' + pull_request: + paths: + - '**.md' + paths-ignore: + - '!**.md' + +jobs: + log: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + with: + submodules: 'recursive' + - name: log file updated + run: | + echo "Updated documentation" + diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 62d08de9e..0cea545cc 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -39,11 +39,7 @@ jobs: filters: | docker: - 'utils/docker/**' -# documentation: -# - '**.md' # base: 'main' -# - name: if docu change then go to end - - name: build dev image if: steps.filter.outputs.docker == 'true' env: @@ -53,7 +49,7 @@ jobs: make -C utils/docker build build-dev - name: fetch dev image - if: steps.filter.outputs.docker == 'false' + if: steps.filter.outputs.docker == 'false' # && steps.filter.outputs.notdocumentation == 'true' env: DOCKER_QUIET_BUILD: 1 From 43d2679eb997a63cb13346936e8019df166d8034 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 17:03:15 -0300 Subject: [PATCH 18/34] fixing doc workflow Signed-off-by: munapower --- .github/workflows/documentation.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index c31dfa420..6de1a2df6 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -5,15 +5,17 @@ name: Update Documentation on: push: - paths: - - '**.md' +# paths: +# - '**.md' paths-ignore: - '!**.md' + - '.github/workflows/**' pull_request: - paths: - - '**.md' +# paths: +# - '**.md' paths-ignore: - '!**.md' + - '.github/workflows/**' jobs: log: From 28dba864233bef7dccd855426ca3bb045264de51 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 17:08:07 -0300 Subject: [PATCH 19/34] testing readme Signed-off-by: munapower --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 4929010d0..d6880e533 100644 --- a/README.md +++ b/README.md @@ -705,6 +705,7 @@ repository is prototype code and not intended for production use. ## Initial Committers + - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From c8585574e2dbb25ee6d8796161405040d0870ebf Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 17:18:17 -0300 Subject: [PATCH 20/34] testing both workflows Signed-off-by: munapower --- README.md | 1 - samples/chaincode/echo-go/chaincode/echo.go | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/README.md b/README.md index d6880e533..4929010d0 100644 --- a/README.md +++ b/README.md @@ -705,7 +705,6 @@ repository is prototype code and not intended for production use. ## Initial Committers - - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index f204e7669..f6f826dac 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -2,9 +2,7 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 -test -test2 -test3*/ +*/ package chaincode From 50f8001509dc3051b4aadda0cc9c043e5636d78f Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 17:38:48 -0300 Subject: [PATCH 21/34] testing both workflows v2 Signed-off-by: munapower --- .github/workflows/documentation.yml | 4 ++-- samples/chaincode/echo-go/chaincode/echo.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 6de1a2df6..68df1d1ca 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -8,14 +8,14 @@ on: # paths: # - '**.md' paths-ignore: - - '!**.md' - '.github/workflows/**' + - '!**.md' pull_request: # paths: # - '**.md' paths-ignore: - - '!**.md' - '.github/workflows/**' + - '!**.md' jobs: log: diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index f6f826dac..04ce4345c 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -2,7 +2,7 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 -*/ +test*/ package chaincode From 22100207fe23147b104dc557aff76f056b9d9530 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 18:06:40 -0300 Subject: [PATCH 22/34] testing both workflows v3 Signed-off-by: munapower --- .github/workflows/documentation.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 68df1d1ca..58486940a 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -9,13 +9,14 @@ on: # - '**.md' paths-ignore: - '.github/workflows/**' - - '!**.md' + - "!**.md" pull_request: # paths: # - '**.md' + types: [ pushed ] paths-ignore: - '.github/workflows/**' - - '!**.md' + - "!**.md" jobs: log: From 7316fe4d51d429dd59b7a6e5746fcb1e4325802e Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 18:08:02 -0300 Subject: [PATCH 23/34] testing both workflows v4 Signed-off-by: munapower --- samples/chaincode/echo-go/chaincode/echo.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index 04ce4345c..b0349ef84 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -2,7 +2,8 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 -test*/ +test +test1*/ package chaincode From 8cc7e9deb5db548e042acf0e32d1614e837bebf6 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 6 Feb 2024 18:42:11 -0300 Subject: [PATCH 24/34] testing both workflows v5 Signed-off-by: munapower --- .github/workflows/documentation.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 58486940a..5e1608cba 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -8,15 +8,13 @@ on: # paths: # - '**.md' paths-ignore: - - '.github/workflows/**' - "!**.md" pull_request: # paths: # - '**.md' - types: [ pushed ] +# types: [ pushed ] paths-ignore: - - '.github/workflows/**' - - "!**.md" + - "!**.md" jobs: log: From 5e0c4cbc998c4c318a648f86040ded1a0fb15f89 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 19 Feb 2024 16:34:18 -0300 Subject: [PATCH 25/34] testing only md code Signed-off-by: munapower --- .github/workflows/documentation.yml | 53 ++++++++++++++++++----------- 1 file changed, 33 insertions(+), 20 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 5e1608cba..aa14b450d 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -3,28 +3,41 @@ # name: Update Documentation -on: +on: push: -# paths: -# - '**.md' - paths-ignore: - - "!**.md" - pull_request: -# paths: -# - '**.md' -# types: [ pushed ] - paths-ignore: - - "!**.md" - + branches: + - main + paths: + - '**.md' +defaults: + run: + shell: bash +permissions: {} jobs: - log: + check-md-only: + name: This job was triggered runs-on: ubuntu-latest - + outputs: + md-only: ${{ steps.test-md-only.outputs.md-only }} + permissions: + contents: read + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + fetch-depth: 2 # required to compare HEAD^ + - run: git diff --name-only HEAD^..HEAD + - name: Test MD only + id: test-md-only + run: >- + [ -z "$(git diff --name-only HEAD^..HEAD | grep -ve "\.md$")" ] && + echo "md-only=${{toJSON(true)}}" >> $GITHUB_OUTPUT || + echo "md-only=${{toJSON(false)}}" >> $GITHUB_OUTPUT + build: + name: Run if only MD files + needs: ['check-md-only'] + runs-on: ubuntu-latest + if: ${{ fromJSON(needs.check-md-only.outputs.md-only) == true }} steps: - - uses: actions/checkout@v4 - with: - submodules: 'recursive' - - name: log file updated - run: | - echo "Updated documentation" + - run: echo ran From 54fb3fb9cf1afa3c4532ed4802e5a1fbb5f68741 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 19 Feb 2024 16:37:34 -0300 Subject: [PATCH 26/34] change Readme only Signed-off-by: munapower --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 4929010d0..37cd743b6 100644 --- a/README.md +++ b/README.md @@ -704,7 +704,6 @@ repository is prototype code and not intended for production use. ## Initial Committers - - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From 6b9df0cb6b69fd6ed0a05cd833e9230677b95f0d Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 19 Feb 2024 16:39:03 -0300 Subject: [PATCH 27/34] change for all branch Signed-off-by: munapower --- .github/workflows/documentation.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index aa14b450d..6dd08dbe3 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -5,8 +5,8 @@ name: Update Documentation on: push: - branches: - - main +# branches: +# - main paths: - '**.md' defaults: From c6aa7b485c28387270c1436d3ff7c48d0f99d8b9 Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 19 Feb 2024 16:39:55 -0300 Subject: [PATCH 28/34] change Readme only Signed-off-by: munapower --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 37cd743b6..4929010d0 100644 --- a/README.md +++ b/README.md @@ -704,6 +704,7 @@ repository is prototype code and not intended for production use. ## Initial Committers + - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) From d1bb34dbe91a1467d5ae3c66c7fe59c7470d17ca Mon Sep 17 00:00:00 2001 From: munapower Date: Mon, 19 Feb 2024 16:41:48 -0300 Subject: [PATCH 29/34] change Readme and echo Signed-off-by: munapower --- README.md | 1 - samples/chaincode/echo-go/chaincode/echo.go | 3 +-- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/README.md b/README.md index 4929010d0..37cd743b6 100644 --- a/README.md +++ b/README.md @@ -704,7 +704,6 @@ repository is prototype code and not intended for production use. ## Initial Committers - - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index b0349ef84..f6f826dac 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -2,8 +2,7 @@ Copyright IBM Corp. All Rights Reserved. SPDX-License-Identifier: Apache-2.0 -test -test1*/ +*/ package chaincode From 5d03c25f0691394454be1c6918d9e49b59fc5576 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 20 Feb 2024 14:56:56 -0300 Subject: [PATCH 30/34] cleanup actions yml Signed-off-by: munapower --- .github/workflows/documentation.yml | 2 -- .github/workflows/test.yml | 3 --- 2 files changed, 5 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 6dd08dbe3..64aa4ba60 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -5,8 +5,6 @@ name: Update Documentation on: push: -# branches: -# - main paths: - '**.md' defaults: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0cea545cc..c27cc19df 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,7 +12,6 @@ on: paths-ignore: - '**.md' - '.github/workflows/**' - env: DOCKER_REGISTRY: 'ghcr.io' PUSH_TO_MAIN: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} @@ -50,7 +49,6 @@ jobs: - name: fetch dev image if: steps.filter.outputs.docker == 'false' - # && steps.filter.outputs.notdocumentation == 'true' env: DOCKER_QUIET_BUILD: 1 run: | @@ -58,7 +56,6 @@ jobs: make -C utils/docker pull pull-dev - name: run make inside dev container - # if: steps.filter.outputs.notdocumentation == 'true' env: DOCKER_DEV_CI_MODE: 1 DOCKER_QUIET_BUILD: 1 From bb2291cf1c33f1654b081a33fcf62406431d7275 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 20 Feb 2024 14:58:30 -0300 Subject: [PATCH 31/34] change only echo Signed-off-by: munapower --- samples/chaincode/echo-go/chaincode/echo.go | 1 - 1 file changed, 1 deletion(-) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index f6f826dac..af1c595d9 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -1,6 +1,5 @@ /* Copyright IBM Corp. All Rights Reserved. - SPDX-License-Identifier: Apache-2.0 */ From 895755d2de137f3a685e7dccae60d923151592e6 Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 20 Feb 2024 15:02:32 -0300 Subject: [PATCH 32/34] cleanup actions yml Signed-off-by: munapower --- .github/workflows/test.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index c27cc19df..36c371a97 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -38,7 +38,6 @@ jobs: filters: | docker: - 'utils/docker/**' -# base: 'main' - name: build dev image if: steps.filter.outputs.docker == 'true' env: @@ -48,7 +47,7 @@ jobs: make -C utils/docker build build-dev - name: fetch dev image - if: steps.filter.outputs.docker == 'false' + if: steps.filter.outputs.docker == 'false' env: DOCKER_QUIET_BUILD: 1 run: | @@ -69,7 +68,7 @@ jobs: # continue only if we push to main and rebuild docker images # - name: Login to the ${{ env.DOCKER_REGISTRY }} Container Registry - if: env.PUSH_TO_MAIN == 'true' && steps.filter.outputs.docker == 'true' + if: env.PUSH_TO_MAIN == 'true' && steps.filter.outputs.docker == 'true' uses: docker/login-action@v2 with: registry: ${{ env.DOCKER_REGISTRY }} From 363071d64c94d7e5bab4d2eb6ed5197b62d4918e Mon Sep 17 00:00:00 2001 From: munapower Date: Tue, 20 Feb 2024 15:11:44 -0300 Subject: [PATCH 33/34] remove readme and echo from PR Signed-off-by: munapower --- README.md | 1 + samples/chaincode/echo-go/chaincode/echo.go | 1 + 2 files changed, 2 insertions(+) diff --git a/README.md b/README.md index 37cd743b6..4929010d0 100644 --- a/README.md +++ b/README.md @@ -704,6 +704,7 @@ repository is prototype code and not intended for production use. ## Initial Committers + - [Marcus Brandenburger](https://github.com/mbrandenburger) (bur@zurich.ibm.com) - [Christian Cachin](https://github.com/cca88) (cca@zurich.ibm.com) - [Rüdiger Kapitza](https://github.com/rrkapitz) (kapitza@ibr.cs.tu-bs.de) diff --git a/samples/chaincode/echo-go/chaincode/echo.go b/samples/chaincode/echo-go/chaincode/echo.go index af1c595d9..f6f826dac 100644 --- a/samples/chaincode/echo-go/chaincode/echo.go +++ b/samples/chaincode/echo-go/chaincode/echo.go @@ -1,5 +1,6 @@ /* Copyright IBM Corp. All Rights Reserved. + SPDX-License-Identifier: Apache-2.0 */ From 808a787c4a815093103c92447510faac204d4cee Mon Sep 17 00:00:00 2001 From: Marcus Brandenburger Date: Thu, 22 Feb 2024 08:31:20 +0100 Subject: [PATCH 34/34] Update .github/workflows/documentation.yml Signed-off-by: Marcus Brandenburger --- .github/workflows/documentation.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 64aa4ba60..d2ed9232e 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -2,7 +2,7 @@ # SPDX-License-Identifier: Apache-2.0 # -name: Update Documentation +name: Check Documentation on: push: paths: