PluginProbe
Github Embed / 1.8
Github Embed v1.8
trunk 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.0.1 2.0.2 2.1.0 2.2.0 2.2.1
github-embed / templates / repository.php

repository.php in Github Embed 1.8, at templates/repository.php

28 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <div class="github-embed github-embed-repository <?php echo $data['logo_class'] ?>">
2 <p>
3 <a href="<?php echo esc_attr( $data['repo']->html_url ) ?>" target="_blank">
4 <strong>
5 <?php echo esc_html( $data['repo']->description ) ?>
6 </strong>
7 </a>
8 <br>
9 <a href="<?php echo esc_attr( $data['repo']->html_url ) ?>" target="_blank"><?php echo esc_html( $data['repo']->html_url ) ?></a><br>
10 <a href="<?php echo esc_attr( $data['repo']->html_url ) ?>/network" target="_blank"><?php echo esc_html( number_format_i18n( $data['repo']->forks_count ) ) ?></a> forks.<br>
11 <a href="<?php echo esc_attr( $data['repo']->html_url ) ?>/stargazers" target="_blank"><?php echo esc_html( number_format_i18n( $data['repo']->stargazers_count ) ) ?></a> stars.<br>
12 <a href="<?php echo esc_attr( $data['repo']->html_url ) ?>/issues" target="_blank"><?php echo esc_html( number_format_i18n( $data['repo']->open_issues_count ) ) ?></a> open issues.<br>
13 Recent commits:
14 <ul class="github_commits">
15 <?php
16 $i = 0;
17 foreach ( $data['commits'] as $commit ) : ?>
18 <li class="github_commit">
19 <a href="https://github.com/<?php echo $data['owner_slug'] ?>/<?php echo $data['repo_slug'] ?>/commit/<?php echo esc_attr( $commit->sha ) ?>" target="_blank"><?php echo esc_html( $commit->commit->message ) ?></a>, <?php echo esc_html( $commit->commit->committer->name ); ?>
20 </li>
21 <?php
22 if (++$i == 5) break;
23 endforeach;
24 ?>
25 </ul>
26 </p>
27 </div>
28