Sharing Prototypes #
Following this tutorial you will learn how to share access to prototypes created with Duet’s Command Line Interface through GitHub Pages.
Before moving further, please make sure you have contributor rights to Duet’s GitHub organization. If not, please contact our support. Additionally, please make sure you have at least version 1.2.0
of Duet CLI installed.
Getting started #
- As the first step, if you haven’t already done this, you should follow our CLI tutorial to create a new project. While doing this it’s important that you choose to initialize the project as a git repository.
- Once you have a project set up, you need to create a new remote repository under Duet’s GitHub organization. To do that, click here. When creating a new repository please make sure to follow our repository naming guidelines.
- Once finished, commit your changes, add the remote origin to your project, and push your first commit to git:
git add README.md
git commit -m "first commit"
git remote add origin git@github.com:duetds/your-repository-name.git
git push -u origin main
- Pushing to
main
branch on git will automatically trigger build and deploy tasks on our CI server. - After the first CI build is completed (you can verify this by switching to
gh-pages
branch on GitHub) you need to go to your repository’s settings, find a settings section called “GitHub Pages,” and once choosemain
and thengh-pages
as the source. This is a required step to make GitHub register your new changes and transfer them to CDN. - After these steps you can access your prototype using https://duetds.github.io/your-repository-name/ where
your-repository-name
is replaced with the actual name. Please note that it takes 10 minutes for all your changes to be visible on this URL after doing changes. - To edit the credentials used to access the prototype, edit
passphrase
found frombuild:encrypt
script in your project’s package.json.
Troubleshooting #
If you experience any issues while getting set up with Duet’s GitHub or CLI, please head over to the Support page for more guidelines and help.