Add rubocop to our build. (#5004)

This commit is contained in:
Guo Xiang Tan
2017-07-28 10:20:09 +09:00
committed by GitHub
parent ff4e295c4f
commit 5012d46cbd
871 changed files with 5480 additions and 6056 deletions

View File

@ -1,7 +1,6 @@
require 'mysql2'
require File.expand_path(File.dirname(__FILE__) + "/base.rb")
# Before running this script, paste these lines into your shell,
# then use arrow keys to edit the values
=begin
@ -125,7 +124,7 @@ class ImportScripts::Bbpress < ImportScripts::Base
end
# gather every existent username
anon_posts.each do |id,post|
anon_posts.each do |id, post|
anon_names[post['name']] = Hash.new if not anon_names[post['name']]
# overwriting email address, one user can only use one email address
anon_names[post['name']]['email'] = post['email']
@ -133,7 +132,7 @@ class ImportScripts::Bbpress < ImportScripts::Base
end
# make sure every user name has a unique email address
anon_names.each do |k,name|
anon_names.each do |k, name|
if not emails.include? name['email']
emails.push ( name['email'])
else
@ -141,7 +140,6 @@ class ImportScripts::Bbpress < ImportScripts::Base
end
end
create_users(anon_names) do |k, n|
{
id: k,