Linux 软件免费装

WP Github Commits

开发者 sudar
更新时间 2021年10月13日 20:19
PHP版本: 3.5 及以上
WordPress版本: 5.8

标签

widget github commits

下载

0.1 0.2 0.3 0.4 0.5 0.6

详情介绍:

Displays the latest commits of a github repo in the sidebar. Features Sidebar Widget The Plugin provides a sidebar widget which can be configured to display commits from a github repo in the sidebar. You can have multiple widgets with different repo configured for each one of them. Template function In addition to using the widget, you can also use the following template function to display the commits of a github repo, anywhere in the theme get_github_commits($user, $repo, $count); The following options can be passed in the $options array Custom field You can also specify the repo for each post or page as a custom field. You can add it under the "WP Github Commits Page fields" section in the Add/Edit post screen. Caching The Plugin caches the commits that is retrieved from Github for 5 hours. Styling using CSS The Plugin adds the following CSS classes. If you want to customize the look of the widget then can change it by adding custom styles to these CSS classes. Troubleshooting If you get timeouts or the error "WP HTTP Error: name lookup timed out" then it means that your server is not timing out before github can respond. You can use the code from this gist to increase the timeout. Translation 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. Development The development of the Plugin happens over at github. If you want to contribute to the Plugin, fork the project at github and send me a pull request. If you are not familiar with either git or Github then refer to this guide to see how fork and send pull request. If you are looking for ideas, then you can start with one of the following TODO items :) TODO Support Stay updated I would be posting updates about this Plugin in my blog and in Twitter. If you want to be informed when new version of this Plugin is released, then you can either subscribe to this blog's RSS feed or follow me in Twitter. Also checkout the other WordPress Plugins that I have created.

安装:

The simplest way to install the plugin is to use the built-in automatic plugin installer. Go to plugins -> Add New and then enter the name of the plugin to automatically install it. If for some reason the above method doesn't work then you can download the plugin as a zip file, extract it and then use your favorite FTP client and then upload the contents of the zip file to the wp-content/plugins/ directory of your WordPress installation and then activate the Plugin from Plugins page.

升级注意事项:

0.6 Trimmed commit messages to 30 characters 0.4 Changed custom field names to make it compatible with other Plugins 0.3 Formatted the date into human readable format 0.2 Added option to take repo name from custom field in a post