Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
orangewolf committed Oct 11, 2018
0 parents commit 953dbfc
Show file tree
Hide file tree
Showing 78 changed files with 1,079 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.bundle/
log/*.log
pkg/
spec/test_app/db/*.sqlite3
spec/test_app/db/*.sqlite3-journal
spec/test_app/log/*.log
spec/test_app/tmp/
14 changes: 14 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
source 'https://rubygems.org'

# Declare your gem's dependencies in bulkrax.gemspec.
# Bundler will treat runtime dependencies like base dependencies, and
# development dependencies will be added by default to the :development group.
gemspec

# Declare any dependencies that are still in development here instead of in
# your gemspec. These might include edge Rails or gems from your path or
# Git. Remember to move these dependencies to your gemspec before releasing
# your gem to rubygems.org.

# To use a debugger
# gem 'byebug', group: [:development, :test]
20 changes: 20 additions & 0 deletions MIT-LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Copyright 2018 Rob Kaufman

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Bulkrax
Short description and motivation.

## Usage
How to use my plugin.

## Installation
Add this line to your application's Gemfile:

```ruby
gem 'bulkrax'
```

And then execute:
```bash
$ bundle
```

Or install it yourself as:
```bash
$ gem install bulkrax
```

## Contributing
Contribution directions go here.

## License
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
26 changes: 26 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
begin
require 'bundler/setup'
rescue LoadError
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
end

require 'rdoc/task'

RDoc::Task.new(:rdoc) do |rdoc|
rdoc.rdoc_dir = 'rdoc'
rdoc.title = 'Bulkrax'
rdoc.options << '--line-numbers'
rdoc.rdoc_files.include('README.md')
rdoc.rdoc_files.include('lib/**/*.rb')
end

APP_RAKEFILE = File.expand_path("../spec/test_app/Rakefile", __FILE__)
load 'rails/tasks/engine.rake'


load 'rails/tasks/statistics.rake'



require 'bundler/gem_tasks'

2 changes: 2 additions & 0 deletions app/assets/config/bulkrax_manifest.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
//= link_directory ../javascripts/bulkrax .js
//= link_directory ../stylesheets/bulkrax .css
Empty file added app/assets/images/bulkrax/.keep
Empty file.
13 changes: 13 additions & 0 deletions app/assets/javascripts/bulkrax/application.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// compiled file. JavaScript code in this file should be added after the last require_* statement.
//
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
// about supported directives.
//
//= require_tree .
15 changes: 15 additions & 0 deletions app/assets/stylesheets/bulkrax/application.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/*
* This is a manifest file that'll be compiled into application.css, which will include all the files
* listed below.
*
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
*
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
* compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS
* files in this directory. Styles in this file should be added after the last require_* statement.
* It is generally better to create a new file per style scope.
*
*= require_tree .
*= require_self
*/
5 changes: 5 additions & 0 deletions app/controllers/bulkrax/application_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module Bulkrax
class ApplicationController < ActionController::Base
protect_from_forgery with: :exception
end
end
4 changes: 4 additions & 0 deletions app/helpers/bulkrax/application_helper.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module Bulkrax
module ApplicationHelper
end
end
4 changes: 4 additions & 0 deletions app/jobs/bulkrax/application_job.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module Bulkrax
class ApplicationJob < ActiveJob::Base
end
end
6 changes: 6 additions & 0 deletions app/mailers/bulkrax/application_mailer.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module Bulkrax
class ApplicationMailer < ActionMailer::Base
default from: '[email protected]'
layout 'mailer'
end
end
5 changes: 5 additions & 0 deletions app/models/bulkrax/application_record.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module Bulkrax
class ApplicationRecord < ActiveRecord::Base
self.abstract_class = true
end
end
14 changes: 14 additions & 0 deletions app/views/layouts/bulkrax/application.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!DOCTYPE html>
<html>
<head>
<title>Bulkrax</title>
<%= stylesheet_link_tag "bulkrax/application", media: "all" %>
<%= javascript_include_tag "bulkrax/application" %>
<%= csrf_meta_tags %>
</head>
<body>

<%= yield %>

</body>
</html>
14 changes: 14 additions & 0 deletions bin/rails
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env ruby
# This command will automatically be run when you run "rails" with Rails gems
# installed from the root of your application.

ENGINE_ROOT = File.expand_path('../..', __FILE__)
ENGINE_PATH = File.expand_path('../../lib/bulkrax/engine', __FILE__)
APP_PATH = File.expand_path('../../spec/test_app/config/application', __FILE__)

# Set up gems listed in the Gemfile.
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])

require 'rails/all'
require 'rails/engine/commands'
22 changes: 22 additions & 0 deletions bulkrax.gemspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
$:.push File.expand_path("../lib", __FILE__)

# Maintain your gem's version:
require "bulkrax/version"

# Describe your gem and declare its dependencies:
Gem::Specification.new do |s|
s.name = "bulkrax"
s.version = Bulkrax::VERSION
s.authors = ["Rob Kaufman"]
s.email = ["[email protected]"]
s.homepage = "TODO"
s.summary = "TODO: Summary of Bulkrax."
s.description = "TODO: Description of Bulkrax."
s.license = "MIT"

s.files = Dir["{app,config,db,lib}/**/*", "MIT-LICENSE", "Rakefile", "README.md"]

s.add_dependency "rails", "~> 5.1.6"

s.add_development_dependency "sqlite3"
end
2 changes: 2 additions & 0 deletions config/routes.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Bulkrax::Engine.routes.draw do
end
5 changes: 5 additions & 0 deletions lib/bulkrax.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
require "bulkrax/engine"

module Bulkrax
# Your code goes here...
end
5 changes: 5 additions & 0 deletions lib/bulkrax/engine.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module Bulkrax
class Engine < ::Rails::Engine
isolate_namespace Bulkrax
end
end
3 changes: 3 additions & 0 deletions lib/bulkrax/version.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module Bulkrax
VERSION = '0.1.0'
end
4 changes: 4 additions & 0 deletions lib/tasks/bulkrax_tasks.rake
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# desc "Explaining what the task does"
# task :bulkrax do
# # Task goes here
# end
6 changes: 6 additions & 0 deletions spec/test_app/Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.

require_relative 'config/application'

Rails.application.load_tasks
5 changes: 5 additions & 0 deletions spec/test_app/app/assets/config/manifest.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@

//= link_tree ../images
//= link_directory ../javascripts .js
//= link_directory ../stylesheets .css
//= link bulkrax_manifest.js
Empty file.
13 changes: 13 additions & 0 deletions spec/test_app/app/assets/javascripts/application.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// compiled file. JavaScript code in this file should be added after the last require_* statement.
//
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
// about supported directives.
//
//= require_tree .
13 changes: 13 additions & 0 deletions spec/test_app/app/assets/javascripts/cable.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
// Action Cable provides the framework to deal with WebSockets in Rails.
// You can generate new channels where WebSocket features live using the `rails generate channel` command.
//
//= require action_cable
//= require_self
//= require_tree ./channels

(function() {
this.App || (this.App = {});

App.cable = ActionCable.createConsumer();

}).call(this);
Empty file.
15 changes: 15 additions & 0 deletions spec/test_app/app/assets/stylesheets/application.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/*
* This is a manifest file that'll be compiled into application.css, which will include all the files
* listed below.
*
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
*
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
* compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS
* files in this directory. Styles in this file should be added after the last require_* statement.
* It is generally better to create a new file per style scope.
*
*= require_tree .
*= require_self
*/
4 changes: 4 additions & 0 deletions spec/test_app/app/channels/application_cable/channel.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module ApplicationCable
class Channel < ActionCable::Channel::Base
end
end
4 changes: 4 additions & 0 deletions spec/test_app/app/channels/application_cable/connection.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
module ApplicationCable
class Connection < ActionCable::Connection::Base
end
end
3 changes: 3 additions & 0 deletions spec/test_app/app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
class ApplicationController < ActionController::Base
protect_from_forgery with: :exception
end
Empty file.
2 changes: 2 additions & 0 deletions spec/test_app/app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
module ApplicationHelper
end
2 changes: 2 additions & 0 deletions spec/test_app/app/jobs/application_job.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
class ApplicationJob < ActiveJob::Base
end
4 changes: 4 additions & 0 deletions spec/test_app/app/mailers/application_mailer.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
class ApplicationMailer < ActionMailer::Base
default from: '[email protected]'
layout 'mailer'
end
3 changes: 3 additions & 0 deletions spec/test_app/app/models/application_record.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
class ApplicationRecord < ActiveRecord::Base
self.abstract_class = true
end
Empty file.
14 changes: 14 additions & 0 deletions spec/test_app/app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<!DOCTYPE html>
<html>
<head>
<title>TestApp</title>
<%= csrf_meta_tags %>

<%= stylesheet_link_tag 'application', media: 'all' %>
<%= javascript_include_tag 'application' %>
</head>

<body>
<%= yield %>
</body>
</html>
13 changes: 13 additions & 0 deletions spec/test_app/app/views/layouts/mailer.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style>
/* Email styles need to be inline */
</style>
</head>

<body>
<%= yield %>
</body>
</html>
1 change: 1 addition & 0 deletions spec/test_app/app/views/layouts/mailer.text.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<%= yield %>
3 changes: 3 additions & 0 deletions spec/test_app/bin/bundle
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/usr/bin/env ruby
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
load Gem.bin_path('bundler', 'bundle')
4 changes: 4 additions & 0 deletions spec/test_app/bin/rails
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env ruby
APP_PATH = File.expand_path('../config/application', __dir__)
require_relative '../config/boot'
require 'rails/commands'
4 changes: 4 additions & 0 deletions spec/test_app/bin/rake
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env ruby
require_relative '../config/boot'
require 'rake'
Rake.application.run
Loading

0 comments on commit 953dbfc

Please sign in to comment.