From 1b30dbfcb0a0744665cf8d8eb8eaca75571e906d Mon Sep 17 00:00:00 2001 From: kardolus Date: Wed, 6 Nov 2024 23:05:12 +0100 Subject: [PATCH] chore: update file paths for resources --- README.md | 2 +- .../chatgpt/resources}/chatgpt-cli.tape | 0 {resources => cmd/chatgpt/resources}/vhs.gif | Bin {resources => test}/testdata/completions.json | 0 {resources => test}/testdata/error.json | 0 {resources => test}/testdata/history.json | 0 {resources => test}/testdata/models.json | 0 test/utils.go | 4 ++-- 8 files changed, 3 insertions(+), 3 deletions(-) rename {resources => cmd/chatgpt/resources}/chatgpt-cli.tape (100%) rename {resources => cmd/chatgpt/resources}/vhs.gif (100%) rename {resources => test}/testdata/completions.json (100%) rename {resources => test}/testdata/error.json (100%) rename {resources => test}/testdata/history.json (100%) rename {resources => test}/testdata/models.json (100%) diff --git a/README.md b/README.md index e1514ab..3b37806 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ ChatGPT CLI provides a powerful command-line interface for seamless interaction with ChatGPT models via OpenAI and Azure, featuring streaming capabilities and extensive configuration options. -![a screenshot](resources/vhs.gif) +![a screenshot](cmd/chatgpt/resources/vhs.gif) ## Table of Contents diff --git a/resources/chatgpt-cli.tape b/cmd/chatgpt/resources/chatgpt-cli.tape similarity index 100% rename from resources/chatgpt-cli.tape rename to cmd/chatgpt/resources/chatgpt-cli.tape diff --git a/resources/vhs.gif b/cmd/chatgpt/resources/vhs.gif similarity index 100% rename from resources/vhs.gif rename to cmd/chatgpt/resources/vhs.gif diff --git a/resources/testdata/completions.json b/test/testdata/completions.json similarity index 100% rename from resources/testdata/completions.json rename to test/testdata/completions.json diff --git a/resources/testdata/error.json b/test/testdata/error.json similarity index 100% rename from resources/testdata/error.json rename to test/testdata/error.json diff --git a/resources/testdata/history.json b/test/testdata/history.json similarity index 100% rename from resources/testdata/history.json rename to test/testdata/history.json diff --git a/resources/testdata/models.json b/test/testdata/models.json similarity index 100% rename from resources/testdata/models.json rename to test/testdata/models.json diff --git a/test/utils.go b/test/utils.go index 004db49..1382939 100644 --- a/test/utils.go +++ b/test/utils.go @@ -17,9 +17,9 @@ func FileToBytes(fileName string) ([]byte, error) { err error ) if strings.Contains(thisFile, "vendor") { - urlPath, err = filepath.Abs(path.Join(thisFile, "../../../../../..", "resources", "testdata", fileName)) + urlPath, err = filepath.Abs(path.Join(thisFile, "../../../../../..", "test", "testdata", fileName)) } else { - urlPath, err = filepath.Abs(path.Join(thisFile, "../..", "resources", "testdata", fileName)) + urlPath, err = filepath.Abs(path.Join(thisFile, "../..", "test", "testdata", fileName)) } if err != nil {