GitHub – Upgrade Gist to Full Project Without Commandline or IDE

github

I've been using GitHub's gist feature for some very lightweight HTML + CSS + JavaScript experiments.

I don't have git on my laptop either as a commandline tool or via some IDE. (I'm hitchhiking around the world with a little netbook.)

Copying and pasting from my favourite text editor to/from Git works just fine.

I also have a proper GitHub account where I have forked some projects, edited little fixes right in the GitHub online editor and issues pull requests upstream. So far for the kind of stuff I'm doing the online tools or GitHub are fine without a commandline or IDE.

But now I'm wondering is there a way to "promote" something which is currently a gist into a full-fledged GitHub project?

Best Answer

There is no way to do this without the command line. GitHub does not have a way to promote gists into a repo.

While the GitHub interface does allow you to edit files in your repository, they have to already be there via a git push from your local.

Should they add the ability to add files via the web interface then you would be able to "promote" a gist into a GitHub repo via a standard copy and paste of its contents. But that would also not carry over any of the gist's history of commits.

If you still want to, you'll have to use the command line or IDE.

  1. Head to your gist and look for the Public/Private Clone URL
  2. Click it.

    You'll see a pop up with info such as this:

    Use this clone URL yourself.
    git clone git@gist.github.com:{SHA-1}.git local-repo

  3. Run the git clone to your local

    You may be required to confirm the download if the authenticity of the host, gist.github.com, cannot be established.

    You may also have to enter your passphrase to connect to GitHub

  4. Update the remote to your GitHub repo, of where you want to push these files.

    git remote set-url origin {git://new.url.here}
    

Now you should be able to push the gist files into a GitHub repo, with all their commit revision history.