Reverted back

This commit is contained in:
Saurabh Bhatia 2014-03-10 18:33:25 +08:00
parent 25a16b944e
commit 5cfc5bfcc3
2 changed files with 2 additions and 21 deletions

View File

@ -1,3 +1,3 @@
# Ruling Orbit
RulingSite-s Version 4.2 Beta
RulingSite-s Version 4.2.2 Beta

View File

@ -4,7 +4,6 @@ class Admin::SitesController < OrbitBackendController
before_filter :is_admin?
before_filter :get_site
before_filter :git_branch
before_filter :get_tag
# def index
# @site = Site.first
@ -77,18 +76,6 @@ class Admin::SitesController < OrbitBackendController
@nginx_version = %x[/opt/nginx/sbin/nginx -v 2>&1].gsub("\n","<br/> ").html_safe
@mongo_version = `mongod --version`.split("\n")[0].html_safe
@linux_version = `lsb_release -d`.split(":")[1].html_safe
@user_actions = UserAction.all.desc(:created_at).page(params[:page]).per(100)
@mail_crons = MailCron.desc(:created_at)
@mail_cron_logs = MailCronLog.desc(:created_at).page(params[:page]).per(100)
respond_to do |format|
format.html # index.html.erb
format.js
end
end
def search_engine
@ -134,7 +121,7 @@ class Admin::SitesController < OrbitBackendController
def check_updates
%x(git fetch origin)
@new_updates = %x(git log #{@current_tag}..#{@latest_tag} --pretty=format:"%ad','%s" --date=short).split("\n").map{|log| log.gsub("'","").split(",")}.to_json
@new_updates = %x(git log #{@branch}..origin/#{@branch} --pretty=format:"%ad','%s" --date=short).split("\n").map{|log| log.gsub("'","").split(",")}.to_json
render :json => @new_updates
end
@ -187,10 +174,4 @@ class Admin::SitesController < OrbitBackendController
@branch = %x(git rev-parse --abbrev-ref HEAD).gsub("\n","")
end
def get_tag
@current_tag = %x(git describe --tags).gsub("\n","")
%x(git fetch --tag).gsub("\n","")
@latest_tag = %x(git describe --tags).gsub("\n","")
end
end