From 43bd4e3e6e86415a7fb96be037f6f4a62036d60b Mon Sep 17 00:00:00 2001 From: codal-nilayp Date: Tue, 3 Feb 2026 17:44:21 +0530 Subject: [PATCH 1/2] Updata Params and readme file --- README.md | 17 +++++++---------- entrypoint.sh | 4 ++++ 2 files changed, 11 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index d9c13f8..16c0557 100644 --- a/README.md +++ b/README.md @@ -32,18 +32,14 @@ jobs: ## Authentication -Authentication is done with [Custom App access tokens](https://shopify.dev/apps/auth/admin-app-access-tokens). +Authentication is done with [Theme Access](https://apps.shopify.com/theme-access). -1. [Create the app](https://help.shopify.com/en/manual/apps/custom-apps#create-and-install-a-custom-app). -2. Click the `Configure Admin API Scopes` button. -3. Enable the following scopes: - - `read_products` - - `write_themes` -4. Click `Save`. -5. From the `API credentials` tab, install the app. -6. Take note of the `Admin API access token`. -7. Add the following to your repository's [GitHub Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository): +1. Install it in your store +2. Generate the theme access token +3. Add the following to your repository's [GitHub Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository): - `SHOP_ACCESS_TOKEN`: the Admin API access token + - Install [Theme Access](https://apps.shopify.com/theme-access) App to your store + - Generate the token and use it - `SHOP_STORE`: Shopify store `.myshopify.com` URL ## Configuration @@ -59,6 +55,7 @@ The `shopify/lighthouse-ci-action` accepts the following arguments: * `pull_theme` - (optional) The ID or name of a theme from which the settings and JSON templates should be used. If not provided Lighthouse will be run against the theme's default settings. * `lhci_min_score_performance` - (optional, default: 0.6) Minimum performance score for a passed audit (must be between 0 and 1). * `lhci_min_score_accessibility` - (optional, default: 0.9) Minimum accessibility score for a passed audit +* `delete_theme_after_result` – (optional, default: 0) Deletes the theme that was created after the process completes.(must be 0 or 1) For the GitHub Status Checks on PR. One of the two arguments is required: diff --git a/entrypoint.sh b/entrypoint.sh index 7c4b2a7..4729619 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -17,6 +17,7 @@ [[ -n "$INPUT_COLLECTION_HANDLE" ]] && export SHOP_COLLECTION_HANDLE="$INPUT_COLLECTION_HANDLE" [[ -n "$INPUT_THEME_ROOT" ]] && export THEME_ROOT="$INPUT_THEME_ROOT" [[ -n "$INPUT_PULL_THEME" ]] && export SHOP_PULL_THEME="$INPUT_PULL_THEME" +[[ -n "$INPUT_DELETE_THEME_AFTER_RESULT" ]] && export SHOP_DELETE_THEME_AFTER_RESULT="$INPUT_DELETE_THEME_AFTER_RESULT" # Authentication creds export SHOP_ACCESS_TOKEN="$INPUT_ACCESS_TOKEN" @@ -246,3 +247,6 @@ EOF step "Running Lighthouse CI" lhci autorun +if [ "$SHOP_DELETE_THEME_AFTER_RESULT" = "1" ]; then + shopify theme delete --theme ${preview_id} -f +fi \ No newline at end of file From 51717971c58e953d4ef2288e48ec571c4c000e21 Mon Sep 17 00:00:00 2001 From: codal-nilayp Date: Tue, 3 Feb 2026 17:45:57 +0530 Subject: [PATCH 2/2] Readme update --- README.md | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 16c0557..b9aa374 100644 --- a/README.md +++ b/README.md @@ -34,12 +34,10 @@ jobs: Authentication is done with [Theme Access](https://apps.shopify.com/theme-access). -1. Install it in your store -2. Generate the theme access token -3. Add the following to your repository's [GitHub Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository): +1. Install it in your store +2. Generate the theme access token +4. Add the following to your repository's [GitHub Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository): - `SHOP_ACCESS_TOKEN`: the Admin API access token - - Install [Theme Access](https://apps.shopify.com/theme-access) App to your store - - Generate the token and use it - `SHOP_STORE`: Shopify store `.myshopify.com` URL ## Configuration