Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

StackBlitz synchronization with github - upload to from StackBlitz to github

I have an angular project and I know it is possible to open a github project in StackBlitz, but what about the changes that were made on the StackBlitz project? Is it possible to commit to github without downloading the code to your PC?

like image 522
Tito Avatar asked Jan 06 '19 15:01

Tito


People also ask

How do I move a repository from GitHub to my computer?

In the upper-right corner of any page, click , and then click Import repository. Under "Your old repository's clone URL", type the URL of the project you want to import. Choose your personal account or an organization to own the repository, then type a name for the repository on GitHub.


3 Answers

For those looking for a way to import an existing GitHub repo into Stackblitz, please read: https://stackblitz.com/docs#import-from-github.

You can run any public repo on Github by providing the username + repo name like so: stackblitz.com/github/{GH_USERNAME}/{REPO_NAME}

And you can also optionally specify a branch, tag, or commit: .../github/{GH_USERNAME}/{REPO_NAME}/tree/{TAG|BRANCH|COMMIT}

like image 192
Paul Sancer Avatar answered Sep 16 '22 16:09

Paul Sancer


Edit: Syncing from GitHub to Stackblitz see Pauls answer

Syncing from Stackblitz to GitHub

Looks like you can synchronize your existing stackblitz-project with your github-account by:

setup integration of github and stackblitz

  1. logging into stackblitz
  2. open a project you have write access
  3. click on synchronization option on top left - a github-login page opens
  4. fill in your gitlab credentials and grant stackblitz accessing github

use commit option once changes are done

Once you change something you can click Commit-Option on top to synchronize back to github - will only be available when step 4. successfully be done.

like image 28
David Renner Avatar answered Sep 20 '22 16:09

David Renner


Just to add to the answer, you do have to save your code to see the "Connect Repository" option pop up. When you click "Connect Repository" then click on "import an existing repository". It doesn't look "clickable" but it is.

like image 40
Ransom9133 Avatar answered Sep 19 '22 16:09

Ransom9133