< Previous Article Next Article >

Using Git

Git is by far the most widely used modern version control system in the world today. Your Pround.js Space is automatically initialized with a new Git repo when created. You can also import any existing Git repo into Profound.js Spaces.

There are two ways you can use Git in Profound.js Spaces:

  • Most people prefer to use the visual point-and-click interface because it makes it quick and easy to perform all of the common tasks in Git. You can switch to the Git tab to use this interface.
  • However, for additional control, Profound.js Spaces also provides a Terminal with full commmand line access to Git.

The Git tab

The Git tab provides a point-and-click way to commit, pull, and push using Git.

When you create a space and click on the Git tab, you may first see unstaged files. Clicking on Actions allows you to perform your first commit from Profound.js Spaces.

noderun-git

The Output panel at the bottom displays a log of Git actions.

After you commit, the files will disappear from the list. However, changed files will start reappearing as you begin making more changes.

Diff view

You can double-click on a modified file to open the editor in side-by-side Diff view. This shows you the changes since the last commit.

diff-view

The left side shows the original content and the right side shows the new content, with the differences highlighted. You can continue to make changes in this view, but only on the right side of the editor.

You can also switch to inline Diff view from side-by-side view.

inline-view

GitHub integration

Profound.js Spaces has direct integration with GitHub and allows you to work with both public and private repositories.

To send a Spaces' repo to GitHub, select Set Up on GitHub from the Actions menu.

setup-on-github

You can also import an existing GitHub repo into a Space by starting a new Space, selecting the Clone Git Repository tab and clicking Show My Repositories under GitHub.

clone-tab

In both cases, you will be prompted to sign in using your GitHub.com credentials and you will have the option of keeping the workspace in sync with GitHub automatically.

If you select to keep the workspace in sync, a Webhook will be added to the GitHub repository that updates the workspace repository whenever code is pushed to GitHub. This behavior can be toggled on/off using the GitHub Sync options on the Actions menu.

github-sync

Questions?

Have questions about this topic? Ask for help on our Profound.js Spaces Discussion Forum.

< Previous Article Next Article >