Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compatibility fixes for Redmine 2.0 #1

Open
wants to merge 20 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion COPYRIGHT.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Redmine Google Analytics is a Redmine plugin to insert the Google Analytics
tracking code into Redmine based on user roles.

Copyright (C) 2008 Eric Davis, Little Stream Software
Copyright (C) 2008-2012 Eric Davis, Little Stream Software

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
Expand Down
10 changes: 6 additions & 4 deletions CREDITS.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
Thanks go to the following people for patches and contributions:

Maintainers

* Eric Davis of Little Stream Software

Contributors

* Eric Davis of Little Stream Software
* Gergő Jónás
* rkallensee https://github.com/rkallensee/redmine-google-analytics-plugin
* Makoto Kawasaki http://makotokw.com
* Tobias Fischer (pagina GmbH): https://github.com/paginagmbh
* Marcelo Romulo Fernandes
* Michael Pirogov
34 changes: 17 additions & 17 deletions README.rdoc
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
= Redmine Google Analytics Plugins

Redmine plugin to insert the Google Analytics tracking code into Redmine based on user roles.
Redmine plugin to insert a Google Analytics (or e.g. Piwik) tracking code into Redmine based on user roles.


== Features

Adds your Google Analytics code to every pageview depending on your User roles; Anonymous user, Authenticated User, and Administrator.
Adds your Google Analytics (or e.g. Piwik) code to every pageview depending on your User roles; Anonymous user, Authenticated User, and/or Administrator.

== Installation and Setup

1. Download the plugin. There are three supported ways:
* Downloading the latest archive file from Little Stream Software projects (https://projects.littlestreamsoftware.com)
* Checkout the source from Git
== Installation and Setup

git clone git://github.com/edavis10/redmine-google-analytics-plugin.git vendor/plugins/google_analytics_plugin
This plugin version requires Redmine >= 2.0.0!

* Install it using Rail's plugin installer
1. Change in the plugin directory of your redmine installation
cd /your_redmine_root/plugins/
2. Download the plugin. There are two supported ways:
* Downloading the latest archive file from the GitHub project page:
wget https://github.com/paginagmbh/redmine-google-analytics-plugin/archive/master.zip
* Checkout the sources from Git:
git clone git://github.com/paginagmbh/redmine-google-analytics-plugin.git plugins/google_analytics_plugin
3. Restart your redmine webserver
4. Login to your Redmine install as an Administrator.
5. Configure your settings in _Administration_ > _Plugins_ > [Google Analytics plugin] - _Configure_

script/plugin install git://github.com/edavis10/redmine-google-analytics-plugin.git
You have to paste the complete Google Analytics or e.g. Piwik tracking code, including the HTML script tags, into the field.

2. Login to your Redmine install as an Administrator.
3. Configure your settings in Administration > Information > Configure

== License

This plugin is licensed under the GNU GPL v2. See COPYRIGHT.txt and GPL.txt for details.

== Project help

If you need help you can contact the maintainer at the Bug Tracker. The bug tracker is located at https://projects.littlestreamsoftware.com

This plugin is licensed under the GNU GPL v2. See COPYRIGHT.txt and GPL.txt for details.
7 changes: 3 additions & 4 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,16 @@ begin
require 'jeweler'
Jeweler::Tasks.new do |s|
s.name = "google_analytics_plugin"
s.summary = "Redmine plugin to insert the Google Analytics tracking code into Redmine based on user roles."
s.summary = "Redmine plugin to insert a Google Analytics (or e.g. Piwik) tracking code into Redmine based on user roles."
s.email = "[email protected]"
s.homepage = "https://projects.littlestreamsoftware.com/projects/TODO"
s.description = "Redmine plugin to insert the Google Analytics tracking code into Redmine based on user roles."
s.description = "Redmine plugin to insert a Google Analytics (or e.g. Piwik) tracking code into Redmine based on user roles."
s.authors = ["Eric Davis"]
s.rubyforge_project = "google_analytics_plugin" # TODO
s.files = FileList[
"[A-Z]*",
"init.rb",
"rails/init.rb",
"{bin,generators,lib,test,app,assets,config,lang}/**/*",
"{bin,generators,lib,test,app,assets,config}/**/*",
'lib/jeweler/templates/.gitignore'
]
end
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.2.0
0.3.0-beta
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p>
<%= l(:google_analytics_directions) %>
<%= raw l(:google_analytics_directions) %>
</p>

<p>
Expand Down
6 changes: 6 additions & 0 deletions config/locales/de.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
de:
google_analytics_directions: Bitte den <a href="http://www.google.com/analytics/">Google Analytics</a>-JavaScript-Code in das Textfeld einfügen und die gewünschten Tracking-Optionen auswählen.
google_analytics_code_label: Google Analytics-Code (inklusive <script>-Tags)
google_analytics_log_anonymous_label: Anonyme Benutzer tracken
google_analytics_log_authenticated_label: Authentifizierte Benutzer tracken
google_analytics_log_administrator_label: Administratoren tracken
6 changes: 6 additions & 0 deletions config/locales/ja.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
ja:
google_analytics_directions: <a href="http://www.google.com/analytics/">Google Analytics</a> トラッキングコードを以下に設定してください。
google_analytics_code_label: トラッキングコード (scriptタグを含む)
google_analytics_log_anonymous_label: 匿名ユーザのトラッキング
google_analytics_log_authenticated_label: ログインユーザのトラッキング
google_analytics_log_administrator_label: 管理者ユーザのトラッキング
6 changes: 6 additions & 0 deletions config/locales/pt-BR.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
pt-BR:
google_analytics_directions: Insira seu código JavaScript <a href="http://www.google.com/analytics/">Google Analytics</a> na área abaixo e escolha suas opções de log.
google_analytics_code_label: Código Google Analytics (incluindo script tags)
google_analytics_log_anonymous_label: Logar usuário anônimo
google_analytics_log_authenticated_label: Logar usuário autenticado
google_analytics_log_administrator_label: Logar usuário administrador
6 changes: 6 additions & 0 deletions config/locales/pt.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
pt:
google_analytics_directions: Insira seu código JavaScript <a href="http://www.google.com/analytics/">Google Analytics</a> na área abaixo e escolha suas opções de log.
google_analytics_code_label: Código Google Analytics (incluindo script tags)
google_analytics_log_anonymous_label: Logar usuário anônimo
google_analytics_log_authenticated_label: Logar usuário autenticado
google_analytics_log_administrator_label: Logar usuário administrador
6 changes: 6 additions & 0 deletions config/locales/ru.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
ru:
google_analytics_directions: Введите ваш JavaScript код от <a href="http://www.google.com/analytics/">Google Analytics</a> в поле ниже и выберите параметры отслеживания.
google_analytics_code_label: Код Google Analytics (включая теги SCRIPT)
google_analytics_log_anonymous_label: Отслеживать анонимных пользователей
google_analytics_log_authenticated_label: Отслеживать авторизованных пользователей
google_analytics_log_administrator_label: Отслеживать администраторов.
19 changes: 10 additions & 9 deletions google_analytics_plugin.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@

Gem::Specification.new do |s|
s.name = %q{google_analytics_plugin}
s.version = "0.2.0"
s.version = "0.3.0-beta"

s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Eric Davis"]
s.date = %q{2009-10-14}
s.description = %q{Redmine plugin to insert the Google Analytics tracking code into Redmine based on user roles.}
s.date = %q{2012-09-02}
s.description = %q{Redmine plugin to insert a Google Analytics (or e.g. Piwik) tracking code into Redmine based on user roles.}
s.email = %q{[email protected]}
s.extra_rdoc_files = [
"README.rdoc"
Expand All @@ -22,24 +22,25 @@ Gem::Specification.new do |s|
"README.rdoc",
"Rakefile",
"VERSION",
"app/views/settings/_google_analytics_settings.rhtml",
"app/views/settings/_google_analytics_settings.html.erb",
"config/locales/de.yml",
"config/locales/en.yml",
"config/locales/hu.yml",
"config/locales/it.yml",
"config/locales/ja.yml",
"config/locales/pt.yml",
"config/locales/pt-BR.yml",
"config/locales/ru.yml",
"init.rb",
"lang/en.yml",
"lang/hu.yml",
"lang/it.yml",
"lib/google_analytics_hooks.rb",
"rails/init.rb",
"test/test_helper.rb"
]
s.homepage = %q{https://projects.littlestreamsoftware.com/projects/TODO}
s.rdoc_options = ["--charset=UTF-8"]
s.require_paths = ["lib"]
s.rubyforge_project = %q{google_analytics_plugin}
s.rubygems_version = %q{1.3.5}
s.summary = %q{Redmine plugin to insert the Google Analytics tracking code into Redmine based on user roles.}
s.summary = %q{Redmine plugin to insert a Google Analytics (or e.g. Piwik) tracking code into Redmine based on user roles.}
s.test_files = [
"test/test_helper.rb"
]
Expand Down
23 changes: 22 additions & 1 deletion init.rb
Original file line number Diff line number Diff line change
@@ -1 +1,22 @@
require File.dirname(__FILE__) + "/rails/init"
require 'redmine'

require_dependency 'google_analytics_hooks'

Redmine::Plugin.register :google_analytics_plugin do
name 'Google Analytics plugin'
author 'Eric Davis & Raphael Kallensee'
description 'Redmine plugin to insert a Google Analytics (or e.g. Piwik) tracking code into Redmine based on user roles.'
url 'https://github.com/rkallensee/redmine-google-analytics-plugin'
version '0.4.0'

requires_redmine :version_or_higher => '2.0.0'

settings :default => {
'google_analytics_code' => '',
'google_analytics_log_anonymous' => true,
'google_analytics_log_authenticated' => true,
'google_analytics_log_administrator' => true
}, :partial => 'google_analytics_settings'

end

6 changes: 0 additions & 6 deletions lang/en.yml

This file was deleted.

5 changes: 0 additions & 5 deletions lang/hu.yml

This file was deleted.

5 changes: 0 additions & 5 deletions lang/it.yml

This file was deleted.

2 changes: 1 addition & 1 deletion lib/google_analytics_hooks.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This class hooks into Redmine's View Listeners in order to
# add content to the page
class GoogleAnalyticsHooks < Redmine::Hook::ViewListener
class GoogleAnalyticsHooks < Redmine::Hook::ViewListener

# Adds the Google Analytics code to the layout if the current user meets
# the conditions setup by the System Administrator
Expand Down
25 changes: 0 additions & 25 deletions rails/init.rb

This file was deleted.