From 70ecaa2db5ec3ed4e7f4ff51b53ff23696b4178a Mon Sep 17 00:00:00 2001 From: Md-Rubel-Ahmed-Rana Date: Thu, 4 Jul 2024 00:31:19 +0600 Subject: [PATCH 1/4] Pipeline name changed for main.yaml --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 5798695..861e9a7 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,4 +1,4 @@ -name: CI/CD +name: Images Push To Docker Hub on: push: From 8f42b28fde33913073c904135a9c6683b98b0c54 Mon Sep 17 00:00:00 2001 From: Md-Rubel-Ahmed-Rana Date: Thu, 4 Jul 2024 00:41:28 +0600 Subject: [PATCH 2/4] auto-merge.yaml updated --- .github/workflows/auto-merge.yml | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/workflows/auto-merge.yml b/.github/workflows/auto-merge.yml index e860e6d..1ada2a6 100644 --- a/.github/workflows/auto-merge.yml +++ b/.github/workflows/auto-merge.yml @@ -12,9 +12,10 @@ jobs: steps: - name: Checkout the repository - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: ref: ${{ github.event.ref }} + fetch-depth: 0 - name: Set up Git run: | @@ -22,12 +23,20 @@ jobs: git config --global user.email 'github-actions[bot]@users.noreply.github.com' - name: Merge to main + id: merge run: | git fetch origin main git checkout main - git merge --no-ff --allow-unrelated-histories ${{ github.event.ref }} + git merge --no-ff --allow-unrelated-histories ${{ github.event.ref }} || echo "Merge conflict detected" > conflict.txt + + - name: Check for conflicts + if: failure() + run: | + cat conflict.txt + exit 1 - name: Push changes to main + if: success() env: GH_TOKEN: ${{ secrets.GH_TOKEN }} run: | From bb0304815026e0ecd17f787c55ba84fb90145f76 Mon Sep 17 00:00:00 2001 From: Md-Rubel-Ahmed-Rana Date: Thu, 4 Jul 2024 01:04:12 +0600 Subject: [PATCH 3/4] redirect error solved on login and register page for dashboard --- frontend/src/pages/login/index.tsx | 2 +- frontend/src/pages/signup/index.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/pages/login/index.tsx b/frontend/src/pages/login/index.tsx index c804316..7bd313d 100644 --- a/frontend/src/pages/login/index.tsx +++ b/frontend/src/pages/login/index.tsx @@ -13,7 +13,7 @@ const LoginPage: NextPageWithLayout = () => { const handleAuth = async () => { setLoading(true); const isLoggedIn = Cookies.get("tmAccessToken"); - if (isLoggedIn) { + if (isLoggedIn !== "undefined") { setLoading(false); return router.push("/dashboard"); } else { diff --git a/frontend/src/pages/signup/index.tsx b/frontend/src/pages/signup/index.tsx index 3de2bf6..f574b69 100644 --- a/frontend/src/pages/signup/index.tsx +++ b/frontend/src/pages/signup/index.tsx @@ -13,7 +13,7 @@ const SignupPage: NextPageWithLayout = () => { const handleAuth = async () => { setLoading(true); const isLoggedIn = Cookies.get("tmAccessToken"); - if (isLoggedIn) { + if (isLoggedIn !== "undefined") { setLoading(false); return router.push("/dashboard"); } else { From 323da6b0a1e6a30a6246c96f0a853218deacb756 Mon Sep 17 00:00:00 2001 From: Md-Rubel-Ahmed-Rana Date: Thu, 4 Jul 2024 00:50:00 +0600 Subject: [PATCH 4/4] Token added on Checkout step --- .github/workflows/auto-merge.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/auto-merge.yml b/.github/workflows/auto-merge.yml index 1ada2a6..853ce78 100644 --- a/.github/workflows/auto-merge.yml +++ b/.github/workflows/auto-merge.yml @@ -16,6 +16,7 @@ jobs: with: ref: ${{ github.event.ref }} fetch-depth: 0 + token: ${{ secrets.GH_TOKEN }} - name: Set up Git run: |