Embed files and gist from Github in your blog posts or pages.
WP Github Gist WordPress Plugin, provides the ability to embed gist and files from Github in your blog posts or pages. Even though Github doesn't provide a way to embed files, this Plugin still works by using the gist-it service.
To embed a gist you have to use the following shortcode
[gist id = "{GIST_ID}" file = "{GIST_FILE}"]
Where {GIST_ID} is the id of your gist and {GIST_FILE} is the file inside gist that you want to display. If there is only one file in the gist, then you can ignore this.
Example
[gist id = "12345" file = "myfile"]
To embed a github file you have to use the following shortcode
[github file = "{GITHUB_FILE}" start_line = "{START_LINE}" end_line = "{END_LINE}"]
eg: [github file = "/sudar/MissileLauncher/blob/master/MissileLauncher.cpp"]
if you want to embed only part of the file, then you can specify the start and end line as well
[github file = "/sudar/MissileLauncher/blob/master/MissileLauncher.cpp" start_line = "10" end_line = "20"]
The pot file is available with the Plugin. If you are willing to do translation for the Plugin, use the pot file to create the .po files for your language and let me know. I will add it to the Plugin after giving credit to you.
Support for the Plugin is available from the Plugin's home page. If you have any questions or suggestions, do leave a comment there or contact me in twitter.
Requires: 2.8 or higher
Compatible up to: 3.2.2
Last Updated: 2012-5-2
Downloads: 205
Got something to say? Need help?