Commit 2a705c4f40a32b1313952a212e92a5d8c5407fc6
1 parent
244a1cad
Exists in
master
and in
4 other branches
Admin logs improved. Commits list box styled
Showing
7 changed files
with
58 additions
and
20 deletions
Show diff stats
app/assets/stylesheets/gitlab_bootstrap.scss
| @@ -202,6 +202,10 @@ a:focus { | @@ -202,6 +202,10 @@ a:focus { | ||
| 202 | color:$style_color; | 202 | color:$style_color; |
| 203 | } | 203 | } |
| 204 | 204 | ||
| 205 | +.nav-tabs > .active > a { | ||
| 206 | + font-weight:bold; | ||
| 207 | +} | ||
| 208 | + | ||
| 205 | /** COLORS **/ | 209 | /** COLORS **/ |
| 206 | .cgray { color:gray; } | 210 | .cgray { color:gray; } |
| 207 | .cred { color:#D12F19; } | 211 | .cred { color:#D12F19; } |
| @@ -443,6 +447,13 @@ form { | @@ -443,6 +447,13 @@ form { | ||
| 443 | background-image: -moz-linear-gradient(#eee 6.6%, #dfdfdf); | 447 | background-image: -moz-linear-gradient(#eee 6.6%, #dfdfdf); |
| 444 | background-image: -o-linear-gradient(#eee 6.6%, #dfdfdf); | 448 | background-image: -o-linear-gradient(#eee 6.6%, #dfdfdf); |
| 445 | 449 | ||
| 450 | + &.small { | ||
| 451 | + line-height: 28px; | ||
| 452 | + font-size: 14px; | ||
| 453 | + line-height:28px; | ||
| 454 | + text-shadow: 0 1px 1px white; | ||
| 455 | + } | ||
| 456 | + | ||
| 446 | form { | 457 | form { |
| 447 | padding:9px 0; | 458 | padding:9px 0; |
| 448 | margin:0px; | 459 | margin:0px; |
| @@ -628,13 +639,6 @@ h3.page_title { | @@ -628,13 +639,6 @@ h3.page_title { | ||
| 628 | line-height: 28px; | 639 | line-height: 28px; |
| 629 | } | 640 | } |
| 630 | 641 | ||
| 631 | -pre.logs { | ||
| 632 | - .log { | ||
| 633 | - font-size:12px; | ||
| 634 | - line-height:18px; | ||
| 635 | - } | ||
| 636 | -} | ||
| 637 | - | ||
| 638 | /** | 642 | /** |
| 639 | * File content holder | 643 | * File content holder |
| 640 | * | 644 | * |
| @@ -676,10 +680,10 @@ pre.logs { | @@ -676,10 +680,10 @@ pre.logs { | ||
| 676 | } | 680 | } |
| 677 | .file_content { | 681 | .file_content { |
| 678 | background:#fff; | 682 | background:#fff; |
| 679 | - color:#514721; | ||
| 680 | font-size: 11px; | 683 | font-size: 11px; |
| 681 | 684 | ||
| 682 | &.wiki { | 685 | &.wiki { |
| 686 | + font-size: 13px; | ||
| 683 | code { | 687 | code { |
| 684 | padding:0 4px; | 688 | padding:0 4px; |
| 685 | } | 689 | } |
| @@ -730,6 +734,33 @@ pre.logs { | @@ -730,6 +734,33 @@ pre.logs { | ||
| 730 | } | 734 | } |
| 731 | } | 735 | } |
| 732 | 736 | ||
| 737 | + &.logs { | ||
| 738 | + background:#eee; | ||
| 739 | + max-height: 700px; | ||
| 740 | + overflow-y: auto; | ||
| 741 | + | ||
| 742 | + ol { | ||
| 743 | + margin-left:40px; | ||
| 744 | + padding: 10px 0; | ||
| 745 | + border-left: 1px solid #CCC; | ||
| 746 | + margin-bottom:0; | ||
| 747 | + background: white; | ||
| 748 | + li { | ||
| 749 | + color:#888; | ||
| 750 | + p { | ||
| 751 | + margin:0; | ||
| 752 | + color:#333; | ||
| 753 | + line-height:24px; | ||
| 754 | + padding-left: 10px; | ||
| 755 | + } | ||
| 756 | + | ||
| 757 | + &:hover { | ||
| 758 | + background:$hover; | ||
| 759 | + } | ||
| 760 | + } | ||
| 761 | + } | ||
| 762 | + } | ||
| 763 | + | ||
| 733 | /** | 764 | /** |
| 734 | * Code file | 765 | * Code file |
| 735 | */ | 766 | */ |
app/views/admin/logs/show.html.haml
app/views/commits/_commits.html.haml
| 1 | - @commits.group_by { |c| c.committed_date.to_date }.each do |day, commits| | 1 | - @commits.group_by { |c| c.committed_date.to_date }.each do |day, commits| |
| 2 | %div.ui-box | 2 | %div.ui-box |
| 3 | - %h5= day.stamp("28 Aug, 2010") | 3 | + %h5.small |
| 4 | + %i.icon-calendar | ||
| 5 | + = day.stamp("28 Aug, 2010") | ||
| 4 | %ul.unstyled= render commits | 6 | %ul.unstyled= render commits |
app/views/commits/_head.html.haml
| @@ -13,12 +13,12 @@ | @@ -13,12 +13,12 @@ | ||
| 13 | %li{:class => "#{branches_tab_class}"} | 13 | %li{:class => "#{branches_tab_class}"} |
| 14 | = link_to project_repository_path(@project) do | 14 | = link_to project_repository_path(@project) do |
| 15 | Branches | 15 | Branches |
| 16 | - %span.number= @project.repo.branch_count | 16 | + %span.badge= @project.repo.branch_count |
| 17 | 17 | ||
| 18 | %li{:class => "#{'active' if current_page?(tags_project_repository_path(@project)) }"} | 18 | %li{:class => "#{'active' if current_page?(tags_project_repository_path(@project)) }"} |
| 19 | = link_to tags_project_repository_path(@project) do | 19 | = link_to tags_project_repository_path(@project) do |
| 20 | Tags | 20 | Tags |
| 21 | - %span.number= @project.repo.tag_count | 21 | + %span.badge= @project.repo.tag_count |
| 22 | 22 | ||
| 23 | 23 | ||
| 24 | - if current_page?(project_commits_path(@project)) && current_user.private_token | 24 | - if current_page?(project_commits_path(@project)) && current_user.private_token |
app/views/commits/compare.html.haml
| @@ -20,7 +20,7 @@ | @@ -20,7 +20,7 @@ | ||
| 20 | = "..." | 20 | = "..." |
| 21 | = text_field_tag :to, params[:to], :placeholder => "aa8b4ef", :class => "xlarge" | 21 | = text_field_tag :to, params[:to], :placeholder => "aa8b4ef", :class => "xlarge" |
| 22 | .actions | 22 | .actions |
| 23 | - = submit_tag "Compare", :class => "btn primary" | 23 | + = submit_tag "Compare", :class => "btn btn-primary" |
| 24 | 24 | ||
| 25 | 25 | ||
| 26 | - unless @commits.empty? | 26 | - unless @commits.empty? |
app/views/merge_requests/show/_commits.html.haml
| 1 | - if @commits.present? | 1 | - if @commits.present? |
| 2 | .ui-box | 2 | .ui-box |
| 3 | - %h5 Commits (#{@commits.count}) | 3 | + %h5 |
| 4 | + %i.icon-list | ||
| 5 | + Commits (#{@commits.count}) | ||
| 4 | .merge-request-commits | 6 | .merge-request-commits |
| 5 | - if @commits.count > 8 | 7 | - if @commits.count > 8 |
| 6 | %ul.first_mr_commits.unstyled | 8 | %ul.first_mr_commits.unstyled |
lib/gitlab/logger.rb
| @@ -8,7 +8,7 @@ module Gitlab | @@ -8,7 +8,7 @@ module Gitlab | ||
| 8 | 8 | ||
| 9 | def self.read_latest | 9 | def self.read_latest |
| 10 | path = Rails.root.join("log/githost.log") | 10 | path = Rails.root.join("log/githost.log") |
| 11 | - logs = `tail -n 50 #{path}`.split("\n") | 11 | + logs = File.read(path).split("\n") |
| 12 | end | 12 | end |
| 13 | end | 13 | end |
| 14 | end | 14 | end |