Link a repository Pro
Point a theme or plugin at a GitHub repository or GitLab project to commit to, and a source to pull updates from.
On this page
Each theme and plugin can have two repositories, on GitHub or GitLab:
| What it's for | |
|---|---|
| My repository | Commits go here. Pull from it too. Leave it empty to keep your changes on this site only. |
| Source | Where the files came from, such as someone else's theme. Pulled for updates, never committed to. |
Open the Repositories dialog#
In the editor, click Git in the toolbar and choose Repositories…. Before a project has a repository, the toolbar button says Add repository (or Connect GitHub, if neither GitHub nor GitLab is connected yet).
Link your repository#
- Under My repository, pick the Host: GitHub or GitLab.
- Enter the Repository (GitLab: Project) as
owner/name,group/nameorgroup/subgroup/name, or paste its address. Pasting a github.com or GitLab address picks the host for you. Or click Choose from GitHub (or GitLab) to pick from your list. - Set the Branch. Commits and pulls use it. It's
mainunless you change it. - If the theme or plugin sits in a subfolder of the repository, set Folder inside the repository, like
themes/my-theme. Leave it empty when the repository holds only these files. - Click Save and test to check that Temper can reach it, or Save.
Create a repository#
In the list from Choose from GitHub, click New repository… (GitLab: New project…). Pick the Owner, which can be you or an organization or group, enter a name, keep Private ticked or not, and click Create repository. The name starts as the project's folder name.
When you can't push#
If your account can't push to the repository, Temper says so: "Your GitHub account cannot push to repo, so nothing can be committed to it." If it belongs to someone else, click Move to source to keep pulling its updates, and link a repository of your own under My repository.
When you change My repository to a different one, Temper offers to Keep old repository as the source for updates.
The Git menu#
Once a project has a repository, the toolbar's Git button shows the host, and its menu has:
| Item | What it does |
|---|---|
| Commit… | Commit the working copy to your repository. See Commit. Says Commit (token cannot push) when your connection can't push. |
| Pull from repo | Bring your repository's changes into the working copy. See Pull. |
| Pull updates from source | Bring the source's changes into the working copy. |
| Connect my repository… | Shown when there's only a source. |
| Open repo on GitHub | Opens the repository in a new tab. |
| Repositories… | The dialog above. |
An amber dot on the button means the project only has a source: there's nowhere to commit yet.
Imported projects#
A project imported from GitHub or GitLab is linked when it arrives. If your connection can push to the repository, it's your repository; if not, it's the source.
What's committed#
Paths listed in the project's .gitignore, usually vendor/ and dist/, are never committed. They're still published with the theme or plugin, so built assets and Composer packages reach the live site.
Repository links are saved with each project. They stay when the licence lapses or Pro is uninstalled, and work again when Pro is back.