Skip to content

Instantly share code, notes, and snippets.

@Forsworns
Forked from mroderick/how-to-add-image-to-gist.md
Created September 20, 2022 12:06
Show Gist options
  • Save Forsworns/ec71ad11c9080fb5354949af7d53cc59 to your computer and use it in GitHub Desktop.
Save Forsworns/ec71ad11c9080fb5354949af7d53cc59 to your computer and use it in GitHub Desktop.
How to add an image to a gist

How to add an image to a gist

  1. Create a gist if you haven't already.

  2. Clone your gist:

    # make sure to replace `<hash>` with your gist's hash
    git clone https://gist.github.com/<hash>.git # with https
    git clone git@gist.github.com:<hash>.git     # or with ssh
  3. Add your image to your gist's repository:

    git add your-image.jpg
  4. Commit the image:

    git commit -m "Add image"
  5. Update gist:

    git push origin master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment