Get startedQuickstart

Quickstart

Create a repository, change it in a workspace, merge the change and put it online, in one sitting.

Tutorial2 min read

In this tutorial you create a repository, plan a small change, make it in a browser workspace, merge it through a review, and put the result online. You need a CodePinion account and nothing installed on your machine.

1. Create a repository

  1. Click New repository at the top of the sidebar.
  2. Name it, and leave yourself as the owner. Once you belong to an organization or team you can create repositories for them instead.
  3. Leave visibility on Private and create it.

The repository opens on its Code tab. To work from your own machine instead, see Git access.

2. Plan the change

  1. Open Planning (requires sign-in) and choose your repository.
  2. Create a sprint with New sprint, then add a task with New task, for example "Add a hello page".

3. Start work on the task

Open the task and click Start work. CodePinion creates a branch for the task, opens a workspace on it, and moves the task to In Progress, so the change and its reason stay linked from the start.

The workspace opens in Studio: a file tree, an editor and a terminal.

4. Make the change and commit

Create a file. For a first app, a small web server is enough:

app.pyPython
from http.server import BaseHTTPRequestHandler, HTTPServer


class Hello(BaseHTTPRequestHandler):
    def do_GET(self):
        self.send_response(200)
        self.end_headers()
        self.wfile.write(b"Hello from CodePinion")


HTTPServer(("0.0.0.0", 8000), Hello).serve_forever()

Then open Source Control in Studio, write a commit message and commit.

5. Review and merge

  1. Open the workspace's Merge tab and create a merge request into your default branch. The task moves to In Review.
  2. Pick a reviewer. They approve it, or request changes.
  3. Merge. The task moves to Done.

6. Put it online

  1. In the repository, open Hosted Apps and create a New hosted app. Auto-detect builds from your Dockerfile if you have one, or with a buildpack if not.
  2. Click Deploy. The app gets its own address under codepinionapps.co.ke.
  3. Open its Logs tab and visit the address to see your request arrive.

Where to go next