Skip to content

Commit

Permalink
Initializing redmine_codimd repository
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandermeindl committed Sep 29, 2018
0 parents commit 45e365b
Show file tree
Hide file tree
Showing 27 changed files with 1,034 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.DS_Store
.buildpath
coverage/
.project
.settings/
49 changes: 49 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
Rails:
Enabled: true

AllCops:
TargetRubyVersion: 2.2
TargetRailsVersion: 5.2

Metrics/AbcSize:
Max: 65

Metrics/BlockLength:
Max: 60

Metrics/ClassLength:
Enabled: false

Metrics/CyclomaticComplexity:
Max: 20

Metrics/LineLength:
Max: 140

Metrics/MethodLength:
Max: 60

Metrics/ModuleLength:
Enabled: false

Metrics/PerceivedComplexity:
Max: 20

Rails/SkipsModelValidations:
Enabled: false

Rails/CreateTableWithTimestamps:
Enabled: false

# we drop this, if we drop Rails 4.2 support
Rails/ApplicationRecord:
Enabled: false

Style/AutoResourceCleanup:
Enabled: true

Style/Documentation:
Enabled: false

Style/ExpandPathArguments:
Enabled: false
36 changes: 36 additions & 0 deletions .slim-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
linters:
LineLength:
max: 140
RuboCop:
ignored_cops:
- Layout/AlignArray
- Layout/AlignHash
- Layout/AlignParameters
- Layout/BlockEndNewline
- Layout/FirstParameterIndentation
- Layout/IndentArray
- Layout/IndentationConsistency
- Layout/IndentationWidth
- Layout/IndentHash
- Layout/MultilineArrayBraceLayout
- Layout/MultilineAssignmentLayout
- Layout/MultilineBlockLayout
- Layout/MultilineHashBraceLayout
- Layout/MultilineMethodCallBraceLayout
- Layout/MultilineMethodCallIndentation
- Layout/MultilineMethodDefinitionBraceLayout
- Layout/MultilineOperationIndentation
- Layout/TrailingBlankLines
- Layout/TrailingWhitespace
- Lint/BlockAlignment
- Lint/EndAlignment
- Lint/Void
- Metrics/BlockLength
- Metrics/BlockNesting
- Metrics/LineLength
- Naming/FileName
- Rails/OutputSafety
- Style/FrozenStringLiteralComment
- Style/IfUnlessModifier
- Style/Next
- Style/WhileUntilModifier
46 changes: 46 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
language: ruby

rvm:
- 2.4.4
- 2.3.7
- 2.2.10

env:
- REDMINE_VER=3.4-stable DB=postgresql
- REDMINE_VER=master DB=postgresql

sudo: true
cache: bundler

addons:
postgresql: "9.6"

before_install:
- export PLUGIN_NAME=redmine_codimd
- export REDMINE_GIT_REPO=git://github.com/redmine/redmine.git
- export REDMINE_PATH=$HOME/redmine
- export BUNDLE_GEMFILE=$REDMINE_PATH/Gemfile
- git clone $REDMINE_GIT_REPO $REDMINE_PATH
- cd $REDMINE_PATH
- if [[ "$REDMINE_VER" != "master" ]]; then git checkout -b $REDMINE_VER origin/$REDMINE_VER; fi
- ln -s $TRAVIS_BUILD_DIR $REDMINE_PATH/plugins/$PLUGIN_NAME
# get additionals plugin (only master supports Redmine v4)
# git clone -b v2-stable git://github.com/alphanodes/additionals.git plugins/additionals
- git clone git://github.com/alphanodes/additionals.git $REDMINE_PATH/plugins/additionals
- cp $TRAVIS_BUILD_DIR/test/support/additional_environment.rb $REDMINE_PATH/config/
- cp $TRAVIS_BUILD_DIR/test/support/database-$DB-travis.yml $REDMINE_PATH/config/database.yml

before_script:
- psql -c 'create database travis_ci_test;' -U postgres
# - bundle exec rake redmine:load_default_data REDMINE_LANG=en
# - bundle exec rake db:structure:dump
# - bundle exec rake db:create
- bundle exec rake db:migrate
- bundle exec rake redmine:plugins:migrate

script:
- export SKIP_COVERAGE=1
- if [[ "$REDMINE_VER" == "master" ]]; then bundle exec rake redmine:plugins:test:units NAME=$PLUGIN_NAME; fi
- if [[ "$REDMINE_VER" == "master" ]]; then bundle exec rake redmine:plugins:test:functionals NAME=$PLUGIN_NAME; fi
- if [[ "$REDMINE_VER" == "master" ]]; then bundle exec rake redmine:plugins:test:integration NAME=$PLUGIN_NAME; fi
- if [[ "$REDMINE_VER" != "master" ]]; then bundle exec rake redmine:plugins:test NAME=$PLUGIN_NAME RUBYOPT="-W0"; fi
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Changelog
=========

v1.0
----

first release
Loading

0 comments on commit 45e365b

Please sign in to comment.