이 플러그인은 최근 3개의 주요 워드프레스 출시와 시험 되지 않았습니다. 워드프레스의 좀 더 최근 버전으로 이용할 때 더 이상 관리되지 않고 지원되지 않고 호환성 문제가 있을 수 있습니다.

GitHub Release Downloads

설명

GitHub Release Downloads allows you to get the download count, links and more information for releases of GitHub repositories.

Download count

The shortcode is [grd_count]. It returns a number corresponding to the sum of all download count values for the selected releases. For instance, you can get the number of total downloads for one GitHub repository.

속성

  • user: the GitHub username.
  • repo: the GitHub repository name.
  • latest: only gets information about the latest published release for the repository.
  • tag: only gets information about the release with the specified tag name.
  • prereleases: includes draft releases and prereleases. Default value is false.

예제

  • All repository downloads: [grd_count user="IvanRF" repo="MassiveFileRenamer"]
  • Latest release downloads: [grd_count user="IvanRF" repo="MassiveFileRenamer" latest="true"]
  • Specific release downloads: [grd_count user="IvanRF" repo="MassiveFileRenamer" tag="v1.6.0"]

Note: user and/or repo can be omitted if default values are set.

Release downloads list

The shortcode is [grd_list]. It returns an HTML list for the selected releases including the release tag name, the release description and the list of files that can be downloaded, like release assets or the source code.
For styling, class selectors are provided (e.g.: release-downloads-header, release-name, etc.).

속성

  • user, repo, latest, tag, prereleases: same as above.
  • hide_description: hides the release description.
  • hide_size: hides information about the file size.
  • hide_downloads: hides information about the download count.
  • downloads_suffix: use it for internationalization. Default value is " downloads".
  • hide_source_code: hides the download link for the source code.

예제

  • All repository downloads: [grd_list user="IvanRF" repo="MassiveFileRenamer"]
  • Latest release downloads: [grd_list user="IvanRF" repo="MassiveFileRenamer" latest="true"]
  • Specific release downloads: [grd_list user="IvanRF" repo="MassiveFileRenamer" tag="v1.5.6"]
  • Hide file size: [grd_list user="IvanRF" repo="MassiveFileRenamer" hide_size="true"]
  • Hide downloads count: [grd_list user="IvanRF" repo="MassiveFileRenamer" hide_downloads="true"]
  • Downloads suffix change: [grd_list user="IvanRF" repo="MassiveFileRenamer" downloads_suffix="descargas"]

Boolean attributes can take any of this values: “1”, “true”, “on” and “yes”; or “0”, “false”, “off” and “no”.

Latest version

The shortcode is [grd_latest_version]. It returns the tag name of the latest published full release.
For tag names like “v1.6.0”, it returns “1.6.0” as the version number.

속성

  • user, repo, prereleases: same as above.

설정을

Under WordPress 설정을 menu you will find the GitHub Release Downloads options page. In this page you can set values for the GitHub username and the repository name to use by default in the shortcodes.

If both values are set, the shortcodes can be used without attributes (e.g.: [grd_count]) since default values for user and repo will be used.
Attribute values take precedence over default values. For example, [grd_count repo="MyRepo"] will use the username default value and the repository specified in the shortcode.

스크린샷

  • Example of [grd_count]. Here is used to get the number for total downloads.
  • Example of [grd_list]. Here it lists all available releases and downloads for a repository.
  • GitHub Release Downloads options page.

설치

  1. Upload the github-release-downloads folder to the /wp-content/plugins/ directory
  2. 워드프레스의 ‘플러그인’ 메뉴에서 플러그인을 활성화하세요.

FAQ

You’ll find more information at ivanrf.com.

후기

2016년 9월 3일 4 replies
Hi Ivan - It is great thought developing a plugin like this. But it didnt worked for me . Could you please help me ? 1. Installed activated 2. In settings page I didnt put any username and repo info 3. I used the shorcode directly showed in examples section like below - [grd_list user="IvanRF" repo="MassiveFileRenamer" latest="true"] it throws me an error says invalid repo. I want to display the repo info of other users. Is it possible ? <Jan21-2016> Latest version is working fine. Thank You
모든 4 평가 읽기

기여자 & 개발자

“GitHub Release Downloads”(은)는 오픈 소스 소프트웨어입니다. 다음의 사람들이 이 플러그인에 기여하였습니다.

기여자

“GitHub Release Downloads”(이)가 2(으)로 번역되었습니다. 기여해 주셔서 번역자님께 감사드립니다.

자국어로 “GitHub Release Downloads”(을)를 번역하세요.

개발에 관심이 있으십니까?

코드 탐색하기는, SVN 저장소를 확인하시거나, 개발 기록RSS로 구독하세요.

변경이력

2.3.1

  • Added Authorization HTTP header, since access_token query parameter is deprecated.
  • Minor fix for a PHP warning.

2.3.0

  • Added release description, with Markdown support.
  • Added download link for release source code.
  • Added attribute to include draft and prereleases.
  • Improved dismissible admin notices.

2.2.0

  • Ignore draft and prereleases for latest version. Thanks @john30 for reporting this.
  • Improved admin notices.

2.1.0

  • Improved downloads list.

2.0.1

  • Removed scopes for access token.
  • Added scopes notes.
  • Added admin notices.

2.0.0.1

  • Fixed some localized strings.

2.0.0

  • Added Access Token to deal with API rate limit.
  • Improved error handling. External errors are shown in order to identify root causes.
  • Added help notes.
  • Moved translations to translate.wordpress.org.

1.1.0

  • Added i18n support for strings and download count.
  • Added Spanish translation.
  • Added Settings link in the Plugins list.
  • Added Donate and Follow Me links.

1.0.1

  • Minor fix for a PHP warning.

1.0

  • Initial release.