Skip to content
This repository has been archived by the owner on Dec 14, 2021. It is now read-only.

Commit

Permalink
Get ready for relase
Browse files Browse the repository at this point in the history
  • Loading branch information
marjinal1st committed Jan 22, 2014
1 parent aeeeb04 commit 1428e49
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 31 deletions.
54 changes: 44 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,63 @@
# Medium::Editor::Rails
# Medium Editor for Rails

TODO: Write a gem description
This gem integrates [Medium Editor](https://github.com/daviferreira/medium-editor) with Rails asset pipeline.

## Version

The latest version of Medium Editor bundled by this gem is [1.5.3](https://github.com/daviferreira/medium-editor/releases)

## Installation

Add this line to your application's Gemfile:
Include **medium-editor-rails** in your Rails project's Gemfile:

gem 'medium-editor-rails'
```ruby
gem 'medium-editor-rails'
```

And then execute:

$ bundle
```bash
$ bundle install
```

## Configuration

Include javascript file in **app/assets/javascripts/application.js**:

```javascript
//= require medium-edior
```

Include stylesheet file on **app/assets/stylesheets/application.css**:

```scss
*= require medium-editor
```

You can also include themes from **themes** folder, example:

```scss
*= require medium-editor/themes/flat
```

## Using Medium Editor with Rails

You need to initialize Medium Editor with any selector of div, example:

Or install it yourself as:
```html
<div class="editable"></div>

$ gem install medium-editor-rails
<script>var editor = new MediumEditor('.editable');</script>
```

## Usage
For extra options, visit this page:

TODO: Write usage instructions here
https://github.com/daviferreira/medium-editor#initialization-options

## Contributing

1. Fork it ( http://github.com/<my-github-username>/medium-editor-rails/fork )
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request
5. Create new Pull Request
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
@@ -1 +1 @@
require "bundler/gem_tasks"
require 'bundler/gem_tasks'
3 changes: 0 additions & 3 deletions lib/medium-editor-rails/engine.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
module MediumEditorRails
module Rails
class Engine < ::Rails::Engine
initializer 'MediumEditorRails precompile hook', :group => :all do |app|
app.config.assets.precompile += %w()
end
end
end
end
4 changes: 2 additions & 2 deletions lib/medium-editor-rails/version.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module MediumEditorRails
module Rails
VERSION = "0.0.1"
MEDIUM_EDITOR_VERSION = ""
VERSION = '0.1.0'
MEDIUM_EDITOR_VERSION = '1.5.3'
end
end
32 changes: 17 additions & 15 deletions medium-editor-rails.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,23 @@ lib = File.expand_path('../lib', __FILE__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
require 'medium-editor-rails/version'

Gem::Specification.new do |spec|
spec.name = "medium-editor-rails"
spec.version = MediumEditorRails::Rails::VERSION
spec.authors = ["Ahmet Sezgin Duran"]
spec.email = ["[email protected]"]
spec.summary = %q{TODO: Write a short summary. Required.}
spec.description = %q{TODO: Write a longer description. Optional.}
spec.homepage = ""
spec.license = "MIT"
Gem::Specification.new do |s|
s.name = 'medium-editor-rails'
s.version = MediumEditorRails::Rails::VERSION
s.authors = ['Ahmet Sezgin Duran']
s.email = ['[email protected]']
s.summary = %q{Medium Editor integrated in Rails asset pipeline}
s.description = s.summary
s.homepage = 'https://github.com/marjinal1st/medium-editor-rails'
s.license = 'MIT'

spec.files = `git ls-files`.split($/)
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
spec.require_paths = ["lib"]
s.files = `git ls-files`.split($/)
s.executables = s.files.grep(%r{^bin/}) { |f| File.basename(f) }
s.test_files = s.files.grep(%r{^(test|spec|features)/})
s.require_paths = ['lib']

spec.add_development_dependency "bundler", "~> 1.5"
spec.add_development_dependency "rake"
s.add_dependency 'rails', '> 3.1'

s.add_development_dependency 'bundler', '~> 1.5'
s.add_development_dependency 'rake'
end

0 comments on commit 1428e49

Please sign in to comment.