Tuesday 6 August 2013

Old Gists

Recently found out I can refer directly to different revisions of a Gist, by adding the hashtag of a revision.

Instead of <script src="https://gist.github.com/maartenl/6048082.js"></script>.

This <script src="https://gist.github.com/maartenl/6048082/95c021aa4e2b1dc1570b5f70c2dcc95a26944fe1.js"></script> will show the revision with hashtag 95c021aa4e2b1dc1570b5f70c2dcc95a26944fe1.

It's very REST-y this way.

It provides an ideal way to show different refactorings in a blog.

Awesome!

References

Embedding a specific revision of a Gist on GitHub.com via JavaScript
http://webapps.stackexchange.com/questions/22792/embedding-a-specific-revision-of-a-gist-on-github-com-via-javascript



No comments:

Post a Comment