Git Repositories
Create and work with Git repositories owned by a Magpie team.
In the native app, Git repositories lists the repositories in the selected Personal or team selection, like the website. Repositories you were added to directly from another team appear under Shared with you. Search covers every team. Opening a repository shows its owning team, visibility, state, default branch and clone URL. You can choose a branch, open folders, read text files and see recent commits. The app shows up to 200 items in a folder, the latest 25 commits, and text files up to 128 KB. Team editors can open Settings from a repository's action menu to change its description or public/private visibility. They can also open Collaborators to grant read-only or read-and-write access to a Magpie user by username, change that access, or remove it. Team members already have access through the team. They can delete a repository from the same menu after confirming that its clone URL will stop working. Copies already cloned onto a computer are unaffected. The app checks the same repository permissions as the website.
Tap New to create a repository in the current selection, with the same
optional README, .gitignore and license as the website. You need edit access to
that team.
Choose HTTPS tokens from the list's menu to see your active tokens, revoke one, or tap New to create one. Pick Read only, Read and write or Write only. The new token is hidden until you tap Reveal token, and is shown only on that screen: tap Share token to send it somewhere private, such as a password manager, before tapping Done. Tokens can only be managed from the app when you are signed in to it, not with an API key.
Git repositories are owned by a Magpie team. A personal repository belongs to your Personal team. A shared repository belongs to the shared team you choose when you create it.
Repository access follows the team. A private repository can also be shared with an individual Magpie user without adding that person to the team. Public repositories can be read by anyone, but writing still requires repository or team write access.
Magpie stores the Git repository separately from the application files. Git remains the source of truth for commits, branches, tags, and files. Repository metadata, team access, and settings are managed in Magpie.
Use Git from a Mac
Magpie's command-line Git connection uses HTTPS. SSH keys are not used for this feature, so there is no SSH key to upload.
Open Get an HTTPS token from the Git Repositories page or a repository page. Give the token Read repositories access to clone or fetch, and Write to repositories access to push. Select both if you need to clone and push. The full token is available once. Magpie cannot show it again. After creating a token, you can reload the page without submitting the form again.
The new token is concealed on screen. Select Copy token to copy it without revealing it, or Reveal to inspect it. Leaving the tab or pressing Escape conceals it again.
The active token list shows each token's name, identifying prefix, and Git access. The prefix is not the token and cannot authenticate Git. The full token is available only when it is created.
If your account already has a Password Vault, Save in Password Vault opens it in a new tab with the token ready to save as an API credential. Unlock Password Vault and save the item. The token is transferred between the two tabs in the browser; it is not sent to Magpie again.
When the repository page provides its HTTPS URL, add it as a named remote. The URL
uses the team and repository names, so cloning it uses the repository name for the
local directory. origin is only a conventional name; a repository can have
several remotes.
git remote add magpie https://magpie.diy/git/<repository-id>.git
git push -u magpie main
When Git asks for credentials, enter your Magpie username and use the access token as the password. Do not use your Magpie account password, and do not put the token in the URL. A macOS Git credential helper can store the token in Keychain.
Cloning creates the origin remote automatically. If you cloned the repository,
push with git push -u origin main; do not add origin a second time.
An access token does not grant repository access by itself. The token's user must also have write access through the repository's team or as a repository collaborator. Revoking the token stops Git access that uses it.
To revoke a token, click Revoke in the token list and confirm. The list updates without leaving the page, and revoked tokens no longer appear after a reload.
The HTTPS transport is being released in stages. If the repository page does not show an HTTPS URL and Git commands, command-line clone and push are not available for that repository yet.
Repository names must be unique within the current team. If the name is already in use, the create form identifies that repository name so you can choose another one.
Team editors can delete a repository from its page. Deletion removes it from Magpie and its Git URLs stop working.
When a repository has no commits, its page says that it is empty. When it has a
README in .github, the repository root, or docs, Magpie renders that README
below the file list using GitHub-Flavored Markdown.
An empty repository can still be cloned. Git creates the local clone and reports that the remote has no commits; add a commit and push it before files can be checked out.
For access or repository state that does not match the page, Contact support.