skip to Main Content

I am trying to connect my partner’s Shopify account to my github (I am using hydrogen).

I see my branches, but I get a "Branch isn't a valid name" error when I try to connect.

The repository is empty and I am wondering what I’m doing wrong.

Screen capture attached.

shopify -> git connection error screen capture

2

Answers


  1. It could be because:

    • Shopify does access your bananasofa/hydrogen repository
    • but its content does not represent a valid theme

    You can see it discussed here, with comments like:

    Check if you have your config folder.
    If it’s missing Shopify will take this as invalid.

    At the very least, it needs a config.yml

    enter image description here

    Login or Signup to reply.
  2. In case anyone else has the same issue..

    Important: the repo can’t be empty, you need to have at least the basic folder structure set up in the repo. Add the basic files as well (theme.liquid, etc), even if they’re empty for now.

    Your theme folders must be in the root of the branch you’re working on, for example, if we look at Dawn’s repo we can see that the main theme folders are in the root of the ‘main’ branch and are not contained within a parent folder:
    example folder structure

    If you’d like to structure your project in such a way that your theme files are in a folder within the root, you’d need to setup some github workflows that will extract the main theme folders out of the parent folder and push that into a separate branch each time you merge into your main branch – you’d then use the separate branch when linking via GH.

    So the simple solution is to just take your theme folders out of any parent folder they might be in and place them in the root of your project instead, after doing so you should not see the error any longer when trying to link your theme via GitHub.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search