From b9208cc8f1fa19bfb0add4d67caf1fed0367a88e Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:11:58 -0400 Subject: [PATCH 1/8] Add original response to the Gif object in case it doesn't have what you need. --- package.json | 2 +- src/index.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 6351e52..54f4feb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "tenorjs-v2", - "version": "1.0.6", + "version": "1.0.7", "description": "A crappy wrapper for Tenor.com API", "main": "./src/index.js", "scripts": { diff --git a/src/index.js b/src/index.js index 2c02a1c..f25227e 100644 --- a/src/index.js +++ b/src/index.js @@ -105,6 +105,7 @@ class Gif { this.id = gif.id; this.created = gif.created; this.mediaUrl = gif.media_formats.gif.url; + this.originalResponse = gif; return this; } } From 073131bd85dfa2ef1ce4f7d8c0d9bb495397a421 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:13:25 -0400 Subject: [PATCH 2/8] Encapsulate branch name in quotes --- .gitea/workflows/deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index e3102d7..49a352e 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -27,7 +27,7 @@ jobs: cd tenorjs-v2 git pull fi - git checkout ${{ gitea.ref_name }} + git checkout "${{ gitea.ref_name }}" - name: Run tests run: | cd /var/lib/act_runner/tenorjs-v2 From e71bba0448bdc131c3875200704a0db05c17d609 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:15:16 -0400 Subject: [PATCH 3/8] Change variables to grab branch name --- .gitea/workflows/deploy.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 49a352e..813a4fc 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -15,7 +15,7 @@ jobs: steps: - name: Pull latest from Git run: | - echo "${{ gitea.ref_name }}" + echo "${{ gitea.action_name }}" pwd whoami mkdir -p /var/lib/act_runner/ @@ -27,7 +27,7 @@ jobs: cd tenorjs-v2 git pull fi - git checkout "${{ gitea.ref_name }}" + git checkout "${{ gitea.action_name }}" - name: Run tests run: | cd /var/lib/act_runner/tenorjs-v2 From 74d2843880aafa9c117718ae4333d7064e9b3d81 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:15:58 -0400 Subject: [PATCH 4/8] name -> ref --- .gitea/workflows/deploy.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 813a4fc..e85ed39 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -15,7 +15,7 @@ jobs: steps: - name: Pull latest from Git run: | - echo "${{ gitea.action_name }}" + echo "${{ gitea.action_ref }}" pwd whoami mkdir -p /var/lib/act_runner/ @@ -27,7 +27,7 @@ jobs: cd tenorjs-v2 git pull fi - git checkout "${{ gitea.action_name }}" + git checkout "${{ gitea.action_ref }}" - name: Run tests run: | cd /var/lib/act_runner/tenorjs-v2 From 7bdae6d9412a78bacdfe5ad1e082a4b9c142481f Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:16:58 -0400 Subject: [PATCH 5/8] Move action_ref to env --- .gitea/workflows/deploy.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index e85ed39..4c35317 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -8,6 +8,7 @@ on: env: DHUB_UNAME: ${{ secrets.DHUB_UNAME }} DHUB_PWORD: ${{ secrets.DHUB_PWORD }} + branch: ${{ github.action_ref }} jobs: build: @@ -15,7 +16,7 @@ jobs: steps: - name: Pull latest from Git run: | - echo "${{ gitea.action_ref }}" + echo "${{ branch }}" pwd whoami mkdir -p /var/lib/act_runner/ @@ -27,7 +28,7 @@ jobs: cd tenorjs-v2 git pull fi - git checkout "${{ gitea.action_ref }}" + git checkout "${{ branch }}" - name: Run tests run: | cd /var/lib/act_runner/tenorjs-v2 From 367f2d8d408054ccdb8071577298bc705b4b2653 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:19:29 -0400 Subject: [PATCH 6/8] Update variable calls --- .gitea/workflows/deploy.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 4c35317..7b659a6 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -16,7 +16,7 @@ jobs: steps: - name: Pull latest from Git run: | - echo "${{ branch }}" + echo "$branch" pwd whoami mkdir -p /var/lib/act_runner/ @@ -28,7 +28,7 @@ jobs: cd tenorjs-v2 git pull fi - git checkout "${{ branch }}" + git checkout "$branch" - name: Run tests run: | cd /var/lib/act_runner/tenorjs-v2 From a00b2846d1ea0c3195edc2a4025106fbcf1029b1 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:20:15 -0400 Subject: [PATCH 7/8] action_ref -> base_ref --- .gitea/workflows/deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 7b659a6..6364b58 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -8,7 +8,7 @@ on: env: DHUB_UNAME: ${{ secrets.DHUB_UNAME }} DHUB_PWORD: ${{ secrets.DHUB_PWORD }} - branch: ${{ github.action_ref }} + branch: ${{ github.base_ref }} jobs: build: From 12147166058f36c8500c752006480ec58b715034 Mon Sep 17 00:00:00 2001 From: Skylar Grant Date: Sun, 22 Sep 2024 20:20:58 -0400 Subject: [PATCH 8/8] base_ref -> head_ref --- .gitea/workflows/deploy.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index 6364b58..0f35030 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -8,7 +8,7 @@ on: env: DHUB_UNAME: ${{ secrets.DHUB_UNAME }} DHUB_PWORD: ${{ secrets.DHUB_PWORD }} - branch: ${{ github.base_ref }} + branch: ${{ github.head_ref }} jobs: build: