Prepare for core integration

pull/6827/head
Oliver Günther 6 years ago
parent ef493b1a56
commit 7dbecdcf79
No known key found for this signature in database
GPG Key ID: A3A8BDAD7C0C552C
  1. 276
      .rubocop.yml
  2. 138
      .travis.yml
  3. 0
      modules/avatars/.gitignore
  4. 0
      modules/avatars/Gemfile.plugins
  5. 0
      modules/avatars/README.md
  6. 0
      modules/avatars/app/assets/stylesheets/avatars/_openproject_avatars.sass
  7. 0
      modules/avatars/app/controllers/avatars/avatar_controller.rb
  8. 0
      modules/avatars/app/controllers/avatars/base_controller.rb
  9. 0
      modules/avatars/app/controllers/avatars/my_avatar_controller.rb
  10. 0
      modules/avatars/app/controllers/avatars/users_controller.rb
  11. 0
      modules/avatars/app/services/avatars/update_service.rb
  12. 0
      modules/avatars/app/views/avatars/my/avatar.html.erb
  13. 0
      modules/avatars/app/views/avatars/users/_avatar.html.erb
  14. 0
      modules/avatars/app/views/avatars/users/_avatar_tab.html.erb
  15. 0
      modules/avatars/app/views/avatars/users/_gravatars.html.erb
  16. 0
      modules/avatars/app/views/avatars/users/_local_avatars.html.erb
  17. 0
      modules/avatars/app/views/settings/_openproject_avatars.html.erb
  18. 0
      modules/avatars/config/locales/de.yml
  19. 0
      modules/avatars/config/locales/en.yml
  20. 0
      modules/avatars/config/locales/js-en.yml
  21. 0
      modules/avatars/config/routes.rb
  22. 0
      modules/avatars/frontend/module/avatar-upload-form/avatar-upload-form.component.ts
  23. 0
      modules/avatars/frontend/module/avatar-upload-form/avatar-upload-form.html
  24. 0
      modules/avatars/frontend/module/globals/global-avatar-fallback.ts
  25. 0
      modules/avatars/frontend/module/main.ts
  26. 0
      modules/avatars/lib/api/v3/users/user_representer_spec.rb
  27. 0
      modules/avatars/lib/open_project/avatars.rb
  28. 0
      modules/avatars/lib/open_project/avatars/avatar_manager.rb
  29. 0
      modules/avatars/lib/open_project/avatars/engine.rb
  30. 0
      modules/avatars/lib/open_project/avatars/patches/avatar_helper_patch.rb
  31. 0
      modules/avatars/lib/open_project/avatars/patches/user_patch.rb
  32. 0
      modules/avatars/lib/open_project/avatars/patches/user_representer_patch.rb
  33. 0
      modules/avatars/lib/open_project/avatars/version.rb
  34. 0
      modules/avatars/lib/openproject-avatars.rb
  35. 0
      modules/avatars/openproject-local_avatars.gemspec
  36. 0
      modules/avatars/package.json
  37. 0
      modules/avatars/spec/controllers/avatars/avatar_controller_spec.rb
  38. 0
      modules/avatars/spec/controllers/avatars/my_controller_spec.rb
  39. 0
      modules/avatars/spec/controllers/avatars/users_controller_spec.rb
  40. 0
      modules/avatars/spec/factories/avatar_attachment_factory.rb
  41. 0
      modules/avatars/spec/features/my_avatar_spec.rb
  42. 0
      modules/avatars/spec/features/shared_avatar_examples.rb
  43. 0
      modules/avatars/spec/features/user_avatar_spec.rb
  44. 0
      modules/avatars/spec/fixtures/invalid.txt
  45. 0
      modules/avatars/spec/fixtures/too_big.jpg
  46. 0
      modules/avatars/spec/fixtures/valid.jpg
  47. 0
      modules/avatars/spec/helpers/avatar_helper_spec.rb
  48. 0
      modules/avatars/spec/models/user_spec.rb
  49. 0
      modules/avatars/spec/services/avatars/update_service_spec.rb
  50. 0
      modules/avatars/spec/shared_examples.rb
  51. 0
      modules/avatars/spec/spec_helper.rb

@ -1,276 +0,0 @@
AllCops:
TargetRubyVersion: 2.2
Exclude:
- db/schema.rb
AccessorMethodName:
Enabled: false
ActionFilter:
Enabled: false
Alias:
Enabled: false
AndOr:
Enabled: false
ArrayJoin:
Enabled: false
AsciiComments:
Enabled: false
AsciiIdentifiers:
Enabled: false
Attr:
Enabled: false
BlockLength:
Enabled: false
BlockNesting:
Enabled: false
CaseEquality:
Enabled: false
CharacterLiteral:
Enabled: false
ClassAndModuleChildren:
Enabled: false
ClassLength:
Enabled: false
ClassVars:
Enabled: false
CollectionMethods:
PreferredMethods:
find: detect
reduce: inject
collect: map
find_all: select
ColonMethodCall:
Enabled: false
CommentAnnotation:
Enabled: false
CyclomaticComplexity:
Enabled: false
Delegate:
Enabled: false
PreferredHashMethods:
Enabled: false
Documentation:
Enabled: false
DotPosition:
EnforcedStyle: leading
DoubleNegation:
Enabled: false
EachWithObject:
Enabled: false
EmptyLiteral:
Enabled: false
Encoding:
Enabled: false
EvenOdd:
Enabled: false
FileName:
Enabled: false
FlipFlop:
Enabled: false
FormatString:
Enabled: false
GlobalVars:
Enabled: false
GuardClause:
Enabled: false
IfUnlessModifier:
Enabled: false
IfWithSemicolon:
Enabled: false
InlineComment:
Enabled: false
AbcSize:
Enabled: false
Lambda:
Enabled: false
LambdaCall:
Enabled: false
LineEndConcatenation:
Enabled: false
LineLength:
Max: 130
MethodLength:
Enabled: false
Metrics/ModuleLength:
Enabled: false
ModuleFunction:
Enabled: false
NegatedIf:
Enabled: false
NegatedWhile:
Enabled: false
Next:
Enabled: false
NilComparison:
Enabled: false
Not:
Enabled: false
NumericLiterals:
Enabled: false
OneLineConditional:
Enabled: false
ParameterLists:
Enabled: false
PercentLiteralDelimiters:
Enabled: false
PerlBackrefs:
Enabled: false
PredicateName:
NamePrefixBlacklist:
- is_
Proc:
Enabled: false
RaiseArgs:
Enabled: false
RegexpLiteral:
Enabled: false
SelfAssignment:
Enabled: false
SingleLineBlockParams:
Enabled: false
SingleLineMethods:
Enabled: false
SignalException:
Enabled: false
SpecialGlobalVars:
Enabled: false
# Forcing single quotes doesn't give any reasonable advantages. To the contrary:
# it forces you to change the quotes every time you want to add interpolation,
# newlines or other escape sequences (\n), or quotes (') to a string. Rubbish.
# Don't even think about performance. That never was a valid argument to begin with.
#
# For the record: using single quotes does NOT have any performance advantages.
# Even if it did, this would be a silly argument.
#
# Ideally we would just use double quotes everywhere but since that would result
# in innumerable rubocop offenses we will just disable this. Quote away.
StringLiterals:
Enabled: false
VariableInterpolation:
Enabled: false
TrivialAccessors:
Enabled: false
VariableInterpolation:
Enabled: false
WhenThen:
Enabled: false
WhileUntilModifier:
Enabled: false
WordArray:
Enabled: false
# Lint
AmbiguousOperator:
Enabled: false
AmbiguousRegexpLiteral:
Enabled: false
AssignmentInCondition:
Enabled: false
ConditionPosition:
Enabled: false
DeprecatedClassMethods:
Enabled: false
ElseLayout:
Enabled: false
HandleExceptions:
Enabled: false
InvalidCharacterLiteral:
Enabled: false
LiteralInCondition:
Enabled: false
LiteralInInterpolation:
Enabled: false
Loop:
Enabled: false
ParenthesesAsGroupedExpression:
Enabled: false
RequireParentheses:
Enabled: false
UnderscorePrefixedVariableName:
Enabled: false
Void:
Enabled: false

@ -1,138 +0,0 @@
#-- copyright
# OpenProject is a project management system.
# Copyright (C) 2012-2018 the OpenProject Foundation (OPF)
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version 3.
#
# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:
# Copyright (C) 2006-2018 Jean-Philippe Lang
# Copyright (C) 2010-2013 the ChiliProject Team
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# See doc/COPYRIGHT.rdoc for more details.
#++
###################################
#
# This file was generated by
# openproject-devkit.
#
# Do not modify this file directly!
#
###################################
language: ruby
rvm:
- 2.5.1
sudo: required
dist: trusty
cache:
bundler: true
directories:
- frontend/node_modules/foundation-apps
- public/assets
- app/assets/javascripts/bundles
- app/assets/javascripts/locales
branches:
only:
- master
- dev
- /^(stable|release)\/.*$/
env:
global:
- CI=true
- RAILS_ENV=test
before_install:
## Custom plugin instructions follow.
# Move the plugin into a subfolder. The plugin-provided Gemfile.plugins
# must refer to this folder.
- mkdir -p plugins/this
- echo `ls -a | tail -n+3 | grep -v plugins` plugins/this/ | xargs mv
# Get OpenProject.
# Doing the fetch detour as you cannot clone into the current directory.
- git init
- git remote add openproject https://github.com/opf/openproject.git
- git fetch --depth=1 openproject
- git checkout openproject/$TRAVIS_BRANCH
# work around https://github.com/travis-ci/travis-ci/issues/8969
- travis_retry gem update --system
# Don't install 1.16.3
- gem install bundler -v 1.16.2
# Install Node latest LTS
# This should only be necessary when preparing the cache or for npm test runs
# but installing later fails for unknown reasons.
- nvm install --lts
bundler_args: --binstubs --without development production docker
stages:
- prepare cache
- test
jobs:
include:
- stage: prepare cache
name: 'Prepare cache'
script:
- bash script/ci/cache_prepare.sh
- stage: test
name: 'plugins:units (1/1) - mysql'
script:
- bash script/ci/setup.sh plugins:units mysql
- bash script/ci/runner.sh plugins:units 1 1
- stage: test
name: 'plugins:units (1/1) - postgres'
script:
- bash script/ci/setup.sh plugins:units postgres
- bash script/ci/runner.sh plugins:units 1 1
- stage: test
name: 'plugins:features (1/1) - mysql'
script:
- bash script/ci/setup.sh plugins:features mysql
- bash script/ci/runner.sh plugins:features 1 1
- stage: test
name: 'plugins:features (1/1) - postgres'
script:
- bash script/ci/setup.sh plugins:features postgres
- bash script/ci/runner.sh plugins:features 1 1
- stage: test
name: 'plugins:cucumber (1/1) - mysql'
script:
- bash script/ci/setup.sh plugins:cucumber mysql
- bash script/ci/runner.sh plugins:cucumber 1 1
- stage: test
name: 'plugins:cucumber (1/1) - postgres'
script:
- bash script/ci/setup.sh plugins:cucumber postgres
- bash script/ci/runner.sh plugins:cucumber 1 1
addons:
chrome: stable
postgresql: "9.6"

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 33 KiB

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Loading…
Cancel
Save