Microhomology 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 82171a97b2db1812ff28de4c26ea59553418e012
4
+ data.tar.gz: 631e0439c1cf32ff546a14cd5aa8f5d1d7d6f4e7
5
+ SHA512:
6
+ metadata.gz: 0980e8500d877fd6200611b3da128feaa5aa3cf9a90971206c5c4823e90b77db6d08c9fc71dba546781325689b84037578fb624b63b2eb982b80c08ffb39989e
7
+ data.tar.gz: a7bb1ed83705c59873633c87dc01977c5d711d5b2e31c2aa9fdd929a300975d9793be5c48d8dfa2f029c3b49a23c42db28b830537b0d674c8f3be9a316b315af
data/.gitignore ADDED
@@ -0,0 +1,17 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ Gemfile.lock
7
+ InstalledFiles
8
+ _yardoc
9
+ coverage
10
+ doc/
11
+ lib/bundler/man
12
+ pkg
13
+ rdoc
14
+ spec/reports
15
+ test/tmp
16
+ test/version_tmp
17
+ tmp
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --color
2
+ --require spec_helper
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.0.0
4
+ cache: bundler
5
+ script: 'bundle exec rspec spec'
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.org'
2
+
3
+ # Specify your gem's dependencies in microhomology.gemspec
4
+ gemspec
data/Guardfile ADDED
@@ -0,0 +1,70 @@
1
+ # A sample Guardfile
2
+ # More info at https://github.com/guard/guard#readme
3
+
4
+ ## Uncomment and set this to only include directories you want to watch
5
+ # directories %w(app lib config test spec features) \
6
+ # .select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")}
7
+
8
+ ## Note: if you are using the `directories` clause above and you are not
9
+ ## watching the project directory ('.'), then you will want to move
10
+ ## the Guardfile to a watched dir and symlink it back, e.g.
11
+ #
12
+ # $ mkdir config
13
+ # $ mv Guardfile config/
14
+ # $ ln -s config/Guardfile .
15
+ #
16
+ # and, you'll have to watch "config/Guardfile" instead of "Guardfile"
17
+
18
+ # Note: The cmd option is now required due to the increasing number of ways
19
+ # rspec may be run, below are examples of the most common uses.
20
+ # * bundler: 'bundle exec rspec'
21
+ # * bundler binstubs: 'bin/rspec'
22
+ # * spring: 'bin/rspec' (This will use spring if running and you have
23
+ # installed the spring binstubs per the docs)
24
+ # * zeus: 'zeus rspec' (requires the server to be started separately)
25
+ # * 'just' rspec: 'rspec'
26
+
27
+ guard :rspec, cmd: "bundle exec rspec" do
28
+ require "guard/rspec/dsl"
29
+ dsl = Guard::RSpec::Dsl.new(self)
30
+
31
+ # Feel free to open issues for suggestions and improvements
32
+
33
+ # RSpec files
34
+ rspec = dsl.rspec
35
+ watch(rspec.spec_helper) { rspec.spec_dir }
36
+ watch(rspec.spec_support) { rspec.spec_dir }
37
+ watch(rspec.spec_files)
38
+
39
+ # Ruby files
40
+ ruby = dsl.ruby
41
+ dsl.watch_spec_files_for(ruby.lib_files)
42
+
43
+ # Rails files
44
+ rails = dsl.rails(view_extensions: %w(erb haml slim))
45
+ dsl.watch_spec_files_for(rails.app_files)
46
+ dsl.watch_spec_files_for(rails.views)
47
+
48
+ watch(rails.controllers) do |m|
49
+ [
50
+ rspec.spec.("routing/#{m[1]}_routing"),
51
+ rspec.spec.("controllers/#{m[1]}_controller"),
52
+ rspec.spec.("acceptance/#{m[1]}")
53
+ ]
54
+ end
55
+
56
+ # Rails config changes
57
+ watch(rails.spec_helper) { rspec.spec_dir }
58
+ watch(rails.routes) { "#{rspec.spec_dir}/routing" }
59
+ watch(rails.app_controller) { "#{rspec.spec_dir}/controllers" }
60
+
61
+ # Capybara features specs
62
+ watch(rails.view_dirs) { |m| rspec.spec.("features/#{m[1]}") }
63
+ watch(rails.layouts) { |m| rspec.spec.("features/#{m[1]}") }
64
+
65
+ # Turnip features and steps
66
+ watch(%r{^spec/acceptance/(.+)\.feature$})
67
+ watch(%r{^spec/acceptance/steps/(.+)_steps\.rb$}) do |m|
68
+ Dir[File.join("**/#{m[1]}.feature")][0] || "spec/acceptance"
69
+ end
70
+ end
data/LICENSE.txt ADDED
@@ -0,0 +1,22 @@
1
+ Copyright (c) 2015 Chris Mikelson
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,156 @@
1
+ ![Microhomology Logo](https://raw.github.com/cmike444/microhomology/master/microhomology.png)
2
+
3
+ By [Chris Mikelson](http://chrismikelson.com)
4
+
5
+ [![Build Status](https://travis-ci.org/cmike444/microhomology.svg?branch=master)](https://travis-ci.org/cmike444/microhomology)
6
+
7
+ Quickly perform microhomology to speed up genetic engineering.
8
+
9
+ With only a few lines of code, researchers can...
10
+
11
+ * Identify microhomology canidate sites in a gene
12
+ * Perform microhomology on sites using multiple strategies
13
+ * Get forward and reverse sequences for each strategy's results
14
+ * Get forward and reverse oligo sequences for each strategy's results
15
+
16
+ This gem uses [BioRuby](https://rubygems.org/gems/bio) to easily obtain compliment pairs and traverse forward or reverse strands.
17
+
18
+ ## Installation
19
+
20
+ Add this line to your application's Gemfile:
21
+
22
+ ```ruby
23
+ gem 'microhomology'
24
+ ```
25
+
26
+ Or install it yourself via Command Line Interface:
27
+
28
+ ```ruby
29
+ $ gem install microhomology
30
+ ```
31
+
32
+ ## Usage
33
+
34
+ >**Note:** This currently relies on the Ensembl REST API for it's data. DNA can only be obtained by using a valid Ensembl Gene ID. Additional options for obtaining DNA via other sources such as text files, formated files or 3rd Party API's is intended to be added at a later date.
35
+
36
+ ## The DNA
37
+ The DNA from Ensembl is masked to differentiate between Introns and Exons.
38
+
39
+ >**Note:** The default is to scan only exons when using a microhomology strategy. Adding options to choose between exons, introns or include both is intended to be added at a later date.
40
+
41
+ ```ruby
42
+ mh = Microhomology::Crispr.new('ENSDARG00000061303', [3, 6, 9])
43
+ ```
44
+
45
+ ```ruby
46
+ mh.dna
47
+ # TTTGCTGTGGTTTCACTCCTTCagaaggtcttatttgttttcttccag
48
+ ```
49
+
50
+ ```ruby
51
+ mh.introns
52
+ # agaaggtcttatttgttttcttccag
53
+ ```
54
+
55
+ ```ruby
56
+ mh.exons
57
+ # TTTGCTGTGGTTTCACTCCTTC
58
+ ```
59
+
60
+ #### CRIPSR
61
+
62
+ Perform microhomology on a DNA sequence using the [CRISPR](https://www.youtube.com/watch?v=2pp17E4E-O8) technique. This class takes two inputs, an Ensembl Gene ID _(string)_ and the microhomology strategies _(array)_. Using the DNA returned from Ensembl and the [CRISPR algorithm](lib/microhomology/strategies.rb), the DNA is scanned to identify target sites on both forward and reverse strands. Once target sites are identified, microhomology is performed according to each strategy in the array.
63
+
64
+ ```ruby
65
+ mh = Microhomology::Crispr.new('ENSDARG00000061303', [6, 12, 24, 48, 96])
66
+ mh.results
67
+ ```
68
+
69
+ ```javascript
70
+ {
71
+ "target": "GGCCGATTCATTAATGCAGCTGG",
72
+ "first": 155,
73
+ "last": 178,
74
+ "microhomology": [
75
+ {
76
+ "strategy": "mh6",
77
+ "forward_strand": "TAATGC",
78
+ "reverse_strand": "ATTACG",
79
+ "mh6_oligo_forward": "TAATGCAGCTGG",
80
+ "mh6_oligo_reverse": "ATTACGTCGACC"
81
+ },
82
+ {
83
+ "strategy": "mh9",
84
+ "forward_strand": "CATTAATGC",
85
+ "reverse_strand": "GTAATTACG",
86
+ "mh9_oligo_forward": "CATTAATGCAGCTGG",
87
+ "mh9_oligo_reverse": "GTAATTACGTCGACC"
88
+ },
89
+ {
90
+ "strategy": "mh12",
91
+ "forward_strand": "ATTCATTAATGC",
92
+ "reverse_strand": "TAAGTAATTACG",
93
+ "mh12_oligo_forward": "ATTCATTAATGCAGCTGG",
94
+ "mh12_oligo_reverse": "TAAGTAATTACGTCGACC"
95
+ },
96
+ {
97
+ "strategy": "mh24",
98
+ "forward_strand": "GCGCGTTGGCCGATTCATTAATGC",
99
+ "reverse_strand": "CGCGCAACCGGCTAAGTAATTACG",
100
+ "mh24_oligo_forward": "GCGCGTTGGCCGATTCATTAATGCAGCTGG",
101
+ "mh24_oligo_reverse": "CGCGCAACCGGCTAAGTAATTACGTCGACC"
102
+ },
103
+ {
104
+ "strategy": "mh48",
105
+ "forward_strand": "CCAATACGCAAACCGCCTCTCCCCGCGCGTTGGCCGATTCATTAATGC",
106
+ "reverse_strand": "GGTTATGCGTTTGGCGGAGAGGGGCGCGCAACCGGCTAAGTAATTACG",
107
+ "mh48_oligo_forward": "CCAATACGCAAACCGCCTCTCCCCGCGCGTTGGCCGATTCATTAATGCAGCTGG",
108
+ "mh48_oligo_reverse": "GGTTATGCGTTTGGCGGAGAGGGGCGCGCAACCGGCTAAGTAATTACGTCGACC"
109
+ }
110
+ ]
111
+ }
112
+ ```
113
+
114
+ See an [CRISPR example](examples/crispr_example.rb) that prints out results to the console.
115
+
116
+ #### TALEN
117
+
118
+ Perform microhomology on a DNA sequence using the [TALEN](https://en.wikipedia.org/wiki/Transcription_activator-like_effector_nuclease) technique. This class takes one input, an Ensembl Gene ID _(string)_. Using the DNA returned from Ensembl and the [TALEN algorithm](lib/microhomology/strategies.rb), the DNA is scanned to identify target sites on both forward and reverse strands. Once target sites are identified, microhomology is performed.
119
+
120
+ ```ruby
121
+ mh = Microhomology::Talen.new('ENSDARG00000061303')
122
+ mh.results
123
+ ```
124
+
125
+ ```javascript
126
+ {
127
+ "target": "TTGCTGTGGTTTCACTCCTTCATCTTCTTGAAGGAGCTCAACCTCCA",
128
+ "first": 1,
129
+ "last": 48,
130
+ "microhomology": [
131
+ {
132
+ "forward_strand": "TTGCTGTGGTTTCACTCCTTCATCTTCTTGAAGGAGCTCAACCTCCA",
133
+ "reverse_strand": "AACGACACCAAAGTGAGGAAGTAGAAGAACTTCCTCGAGTTGGAGGT",
134
+ "oligo_forward": "TTGCTGTGGTTTCACTCTTCTTGACCTTCATAGGAGCTCAACCTCCA",
135
+ "oligo_reverse": "AACGACACCAAAGTGAGAAGAACTGGAAGTATCCTCGAGTTGGAGGT"
136
+ },
137
+ ]
138
+ }
139
+ ```
140
+
141
+ See an [TALEN example](examples/talen_example.rb) that prints out results to the console.
142
+
143
+ ## Roadmap
144
+ Changes to this gem will be ongoing. If you would like to contribute, please follow the process below.
145
+
146
+ * Better integration with Rails
147
+ * Additional DNA data source options
148
+ * Intron and Exon options
149
+
150
+ ## Contributing
151
+
152
+ 1. Fork it ( http://github.com/<my-github-username>/microhomology/fork )
153
+ 2. Create your feature branch (`git checkout -b my-new-feature`)
154
+ 3. Commit your changes (`git commit -am 'Add some feature'`)
155
+ 4. Push to the branch (`git push origin my-new-feature`)
156
+ 5. Create new Pull Request
data/Rakefile ADDED
@@ -0,0 +1,7 @@
1
+ require 'rspec/core/rake_task'
2
+ require 'bundler/gem_tasks'
3
+
4
+ RSpec::Core::RakeTask.new
5
+
6
+ task :default => :spec
7
+ task :test => :spec
@@ -0,0 +1,26 @@
1
+ require 'rubygems'
2
+ require 'microhomology'
3
+
4
+ mh = Microhomology::Crispr.new('ENSDARG00000061303', [6, 12, 24, 48, 96])
5
+ puts ' '
6
+ puts mh.key # The Ensembl Gene ID
7
+ puts mh.dna # The DNA data
8
+ puts mh.introns # The DNA data (only introns)
9
+ puts mh.exons # The DNA data (only exons)
10
+ puts mh.strategies # The microhomology strategies
11
+
12
+ mh.results.each do |target|
13
+ puts ' '
14
+ puts "Target: " + target['target'] # Identified target site
15
+ puts "First: " + target['first'].to_s # Position (from left) of first base pair
16
+ puts "Last: " + target['last'].to_s # Position (from left) of last base pair
17
+
18
+ target['microhomology'].each do |result|
19
+ puts " "
20
+ puts " Strategy: " + result["strategy"].to_s # Microhomology strategy
21
+ puts " Forward: " + result["forward_strand"] # Forward Strand
22
+ puts " Reverse: " + result["reverse_strand"] # Reverse Strand
23
+ puts " Oligo Forward: " + result["oligo_forward"] # Oligo Forward Strand
24
+ puts " Oligo Reverse: " + result["oligo_reverse"] # Oligo Reverse Strand
25
+ end
26
+ end
@@ -0,0 +1,24 @@
1
+ require 'rubygems'
2
+ require 'microhomology'
3
+
4
+ mh = Microhomology::Talen.new('ENSDARG00000061303')
5
+ puts ' '
6
+ puts mh.key # The Ensembl Gene ID
7
+ puts mh.dna # The DNA data
8
+ puts mh.introns # The DNA data (only introns)
9
+ puts mh.exons # The DNA data (only exons)
10
+
11
+ mh.results.each do |target|
12
+ puts ' '
13
+ puts "Target: " + target['target'] # Identified target site
14
+ puts "First: " + target['first'].to_s # Position (from left) of first base pair
15
+ puts "Last: " + target['last'].to_s # Position (from left) of last base pair
16
+
17
+ target['microhomology'].each do |result|
18
+ puts " "
19
+ puts " Forward: " + result["forward_strand"] # Forward Strand
20
+ puts " Reverse: " + result["reverse_strand"] # Reverse Strand
21
+ puts " Oligo Forward: " + result["oligo_forward"] # Oligo Forward Strand
22
+ puts " Oligo Reverse: " + result["oligo_reverse"] # Oligo Reverse Strand
23
+ end
24
+ end
@@ -0,0 +1,135 @@
1
+ require "microhomology/version"
2
+ require "microhomology/strategies"
3
+ require 'bio'
4
+ require 'json'
5
+ require "open-uri"
6
+
7
+ module Microhomology
8
+
9
+ class Crispr
10
+ attr_accessor :key, :strategies, :dna, :results
11
+
12
+ def initialize(key, strategies)
13
+ @key = key
14
+ @strategies = strategies
15
+ @dna = open(get_ensembl_url).read
16
+ @results = perform_microhomology
17
+ end
18
+
19
+ def get_ensembl_url
20
+ "http://rest.ensembl.org/sequence/id/#{self.key}?content-type=text/plain;mask_feature=true"
21
+ end
22
+
23
+ def get_bio_sequence
24
+ Bio::Sequence::NA.new(self.dna)
25
+ end
26
+
27
+ def exons
28
+ self.dna.scan /[A-Z]+/
29
+ end
30
+
31
+ def introns
32
+ self.dna.scan /[a-z]+/
33
+ end
34
+
35
+ def perform_microhomology
36
+ targets = []
37
+ self.dna.scan(Microhomology::CRISPR) do |crispr|
38
+ # Compile first set of data to JSON
39
+ targets << {
40
+ "target" => crispr,
41
+ "first" => Regexp.last_match.offset(0).first,
42
+ "last" => Regexp.last_match.offset(0).last,
43
+ "microhomology" => []
44
+ }
45
+ end
46
+
47
+ if targets
48
+ targets.each do |target|
49
+
50
+ self.strategies.each do |strategy|
51
+ # Double strand break based on polarity
52
+ if target["target"][0] == "G"
53
+ mh_last_char = target["last"] - 7
54
+ else
55
+ mh_last_char = target["first"] + 5
56
+ end
57
+ mh_first_char = mh_last_char - (strategy - 1)
58
+
59
+ target["microhomology"] << {
60
+ "strategy" => "#{strategy}",
61
+ "forward_strand" => get_bio_sequence[mh_first_char..mh_last_char].upcase,
62
+ "reverse_strand" => get_bio_sequence[mh_first_char..mh_last_char].complement.reverse.upcase,
63
+ "oligo_forward" => get_bio_sequence[mh_first_char...target["last"]].upcase,
64
+ "oligo_reverse" => get_bio_sequence[mh_first_char...target["last"]].complement.reverse.upcase
65
+ }
66
+ end
67
+ end
68
+ targets
69
+ else
70
+ "Sorry, no CRISPR targets found."
71
+ end
72
+ end
73
+ end
74
+
75
+ class Talen
76
+ attr_accessor :key, :dna, :results
77
+
78
+ def initialize(key)
79
+ @key = key
80
+ @dna = open(get_ensembl_url).read
81
+ @results = perform_microhomology
82
+ end
83
+
84
+ def get_ensembl_url
85
+ "http://rest.ensembl.org/sequence/id/#{self.key}?content-type=text/plain;mask_feature=true"
86
+ end
87
+
88
+ def exons
89
+ self.dna.scan /[A-Z]+/
90
+ end
91
+
92
+ def introns
93
+ self.dna.scan /[a-z]+/
94
+ end
95
+
96
+ def perform_microhomology
97
+ targets = []
98
+ self.dna.scan(Microhomology::TALEN) do |talen|
99
+ targets << {
100
+ "target" => talen,
101
+ "first" => Regexp.last_match.offset(0).first,
102
+ "last" => Regexp.last_match.offset(0).last,
103
+ "microhomology" => []
104
+ }
105
+ end
106
+
107
+ if targets
108
+ targets.each do |target|
109
+
110
+ talen_site = Bio::Sequence::NA.new(target['target'])
111
+ talen_site_complement = talen_site.complement.reverse
112
+
113
+ talen1 = talen_site[0..15]
114
+ spacer1 = talen_site[16..22]
115
+ spacer2 = talen_site[23..30]
116
+ talen2 = talen_site[31..47]
117
+
118
+ talen_forward = Bio::Sequence::NA.new("#{talen1}#{spacer2}#{spacer1}#{talen2}")
119
+ talen_reverse = talen_forward.complement.reverse
120
+
121
+ target["microhomology"] << {
122
+ "forward_strand" => "#{talen_site.upcase}",
123
+ "reverse_strand" => "#{talen_site_complement.upcase}",
124
+ "oligo_forward" => "#{talen_forward.upcase}",
125
+ "oligo_reverse" => "#{talen_reverse.upcase}"
126
+ }
127
+ end
128
+ targets
129
+ else
130
+ "Sorry, no TALEN targets found."
131
+ end
132
+ end
133
+
134
+ end
135
+ end
@@ -0,0 +1,4 @@
1
+ module Microhomology
2
+ TALEN = /[T].{45}[A]/
3
+ CRISPR = /[G][G].{19}[G][G]|[C][C].{19}[C][C]/
4
+ end
@@ -0,0 +1,3 @@
1
+ module Microhomology
2
+ VERSION = "0.1.0"
3
+ end
@@ -0,0 +1,30 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'microhomology/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "Microhomology"
8
+ spec.version = Microhomology::VERSION
9
+ spec.authors = ["Chris Mikelson"]
10
+ spec.email = ["chrismikelson@gmail.com"]
11
+ spec.summary = %q{Perform simultaneous microhomology strategies with ease using CRISPR or TALEN techniques.}
12
+ spec.description = %q{Simultaneously perform custom microhomoly strategies for genetic engineering and bioinformatics.}
13
+ spec.homepage = "https://github.com/cmike444/microhomology"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_development_dependency "bundler", "~> 1.5"
22
+ spec.add_development_dependency "rake", '~> 0'
23
+ spec.add_development_dependency "rspec"
24
+ spec.add_development_dependency "guard"
25
+ spec.add_development_dependency "guard-rspec"
26
+ spec.add_development_dependency "coveralls"
27
+
28
+ spec.add_runtime_dependency "json", '~> 1.8', '>= 1.8.3'
29
+ spec.add_runtime_dependency "bio", '~> 1.5', '>= 1.5.0'
30
+ end
data/microhomology.png ADDED
Binary file
@@ -0,0 +1,10 @@
1
+ require 'spec_helper'
2
+
3
+ describe Microhomology do
4
+ context "on new crispr" do
5
+ it "adds key to ensembl url" do
6
+ crispr = Microhomology::Crispr.new('ENSDARG00000061303', [6, 12, 24, 48, 96])
7
+ expect(crispr.get_ensembl_url).to eq "http://rest.ensembl.org/sequence/id/ENSDARG00000061303?content-type=text/plain;mask_feature=true"
8
+ end
9
+ end
10
+ end
@@ -0,0 +1,99 @@
1
+ # This file was generated by the `rspec --init` command. Conventionally, all
2
+ # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
3
+ # The generated `.rspec` file contains `--require spec_helper` which will cause
4
+ # this file to always be loaded, without a need to explicitly require it in any
5
+ # files.
6
+ #
7
+ # Given that it is always loaded, you are encouraged to keep this file as
8
+ # light-weight as possible. Requiring heavyweight dependencies from this file
9
+ # will add to the boot time of your test suite on EVERY test run, even for an
10
+ # individual file that may not need all of that loaded. Instead, consider making
11
+ # a separate helper file that requires the additional dependencies and performs
12
+ # the additional setup, and require it from the spec files that actually need
13
+ # it.
14
+ #
15
+ # The `.rspec` file also contains a few flags that are not defaults but that
16
+ # users commonly want.
17
+ #
18
+ # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
19
+
20
+ require 'microhomology'
21
+
22
+ RSpec.configure do |config|
23
+ # rspec-expectations config goes here. You can use an alternate
24
+ # assertion/expectation library such as wrong or the stdlib/minitest
25
+ # assertions if you prefer.
26
+ config.expect_with :rspec do |expectations|
27
+ # This option will default to `true` in RSpec 4. It makes the `description`
28
+ # and `failure_message` of custom matchers include text for helper methods
29
+ # defined using `chain`, e.g.:
30
+ # be_bigger_than(2).and_smaller_than(4).description
31
+ # # => "be bigger than 2 and smaller than 4"
32
+ # ...rather than:
33
+ # # => "be bigger than 2"
34
+ expectations.include_chain_clauses_in_custom_matcher_descriptions = true
35
+ end
36
+
37
+ # rspec-mocks config goes here. You can use an alternate test double
38
+ # library (such as bogus or mocha) by changing the `mock_with` option here.
39
+ config.mock_with :rspec do |mocks|
40
+ # Prevents you from mocking or stubbing a method that does not exist on
41
+ # a real object. This is generally recommended, and will default to
42
+ # `true` in RSpec 4.
43
+ mocks.verify_partial_doubles = true
44
+ end
45
+
46
+ # The settings below are suggested to provide a good initial experience
47
+ # with RSpec, but feel free to customize to your heart's content.
48
+ =begin
49
+ # These two settings work together to allow you to limit a spec run
50
+ # to individual examples or groups you care about by tagging them with
51
+ # `:focus` metadata. When nothing is tagged with `:focus`, all examples
52
+ # get run.
53
+ config.filter_run :focus
54
+ config.run_all_when_everything_filtered = true
55
+
56
+ # Allows RSpec to persist some state between runs in order to support
57
+ # the `--only-failures` and `--next-failure` CLI options. We recommend
58
+ # you configure your source control system to ignore this file.
59
+ config.example_status_persistence_file_path = "spec/examples.txt"
60
+
61
+ # Limits the available syntax to the non-monkey patched syntax that is
62
+ # recommended. For more details, see:
63
+ # - http://myronmars.to/n/dev-blog/2012/06/rspecs-new-expectation-syntax
64
+ # - http://www.teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
65
+ # - http://myronmars.to/n/dev-blog/2014/05/notable-changes-in-rspec-3#new__config_option_to_disable_rspeccore_monkey_patching
66
+ config.disable_monkey_patching!
67
+
68
+ # This setting enables warnings. It's recommended, but in some cases may
69
+ # be too noisy due to issues in dependencies.
70
+ config.warnings = true
71
+
72
+ # Many RSpec users commonly either run the entire suite or an individual
73
+ # file, and it's useful to allow more verbose output when running an
74
+ # individual spec file.
75
+ if config.files_to_run.one?
76
+ # Use the documentation formatter for detailed output,
77
+ # unless a formatter has already been configured
78
+ # (e.g. via a command-line flag).
79
+ config.default_formatter = 'doc'
80
+ end
81
+
82
+ # Print the 10 slowest examples and example groups at the
83
+ # end of the spec run, to help surface which specs are running
84
+ # particularly slow.
85
+ config.profile_examples = 10
86
+
87
+ # Run specs in random order to surface order dependencies. If you find an
88
+ # order dependency and want to debug it, you can fix the order by providing
89
+ # the seed, which is printed after each run.
90
+ # --seed 1234
91
+ config.order = :random
92
+
93
+ # Seed global randomization in this process using the `--seed` CLI option.
94
+ # Setting this allows you to use `--seed` to deterministically reproduce
95
+ # test failures related to randomization by passing the same `--seed` value
96
+ # as the one that triggered the failure.
97
+ Kernel.srand config.seed
98
+ =end
99
+ end
metadata ADDED
@@ -0,0 +1,189 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: Microhomology
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Chris Mikelson
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-09-27 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: bundler
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ~>
18
+ - !ruby/object:Gem::Version
19
+ version: '1.5'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ~>
25
+ - !ruby/object:Gem::Version
26
+ version: '1.5'
27
+ - !ruby/object:Gem::Dependency
28
+ name: rake
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ~>
32
+ - !ruby/object:Gem::Version
33
+ version: '0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ~>
39
+ - !ruby/object:Gem::Version
40
+ version: '0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: rspec
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - '>='
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - '>='
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: guard
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - '>='
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: guard-rspec
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - '>='
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - '>='
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: coveralls
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - '>='
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - '>='
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: json
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ~>
102
+ - !ruby/object:Gem::Version
103
+ version: '1.8'
104
+ - - '>='
105
+ - !ruby/object:Gem::Version
106
+ version: 1.8.3
107
+ type: :runtime
108
+ prerelease: false
109
+ version_requirements: !ruby/object:Gem::Requirement
110
+ requirements:
111
+ - - ~>
112
+ - !ruby/object:Gem::Version
113
+ version: '1.8'
114
+ - - '>='
115
+ - !ruby/object:Gem::Version
116
+ version: 1.8.3
117
+ - !ruby/object:Gem::Dependency
118
+ name: bio
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - ~>
122
+ - !ruby/object:Gem::Version
123
+ version: '1.5'
124
+ - - '>='
125
+ - !ruby/object:Gem::Version
126
+ version: 1.5.0
127
+ type: :runtime
128
+ prerelease: false
129
+ version_requirements: !ruby/object:Gem::Requirement
130
+ requirements:
131
+ - - ~>
132
+ - !ruby/object:Gem::Version
133
+ version: '1.5'
134
+ - - '>='
135
+ - !ruby/object:Gem::Version
136
+ version: 1.5.0
137
+ description: Simultaneously perform custom microhomoly strategies for genetic engineering
138
+ and bioinformatics.
139
+ email:
140
+ - chrismikelson@gmail.com
141
+ executables: []
142
+ extensions: []
143
+ extra_rdoc_files: []
144
+ files:
145
+ - .gitignore
146
+ - .rspec
147
+ - .travis.yml
148
+ - Gemfile
149
+ - Guardfile
150
+ - LICENSE.txt
151
+ - README.md
152
+ - Rakefile
153
+ - examples/crispr_example.rb
154
+ - examples/talen_example.rb
155
+ - lib/microhomology.rb
156
+ - lib/microhomology/strategies.rb
157
+ - lib/microhomology/version.rb
158
+ - microhomology.gemspec
159
+ - microhomology.png
160
+ - spec/microhomology_helper.rb
161
+ - spec/spec_helper.rb
162
+ homepage: https://github.com/cmike444/microhomology
163
+ licenses:
164
+ - MIT
165
+ metadata: {}
166
+ post_install_message:
167
+ rdoc_options: []
168
+ require_paths:
169
+ - lib
170
+ required_ruby_version: !ruby/object:Gem::Requirement
171
+ requirements:
172
+ - - '>='
173
+ - !ruby/object:Gem::Version
174
+ version: '0'
175
+ required_rubygems_version: !ruby/object:Gem::Requirement
176
+ requirements:
177
+ - - '>='
178
+ - !ruby/object:Gem::Version
179
+ version: '0'
180
+ requirements: []
181
+ rubyforge_project:
182
+ rubygems_version: 2.2.1
183
+ signing_key:
184
+ specification_version: 4
185
+ summary: Perform simultaneous microhomology strategies with ease using CRISPR or TALEN
186
+ techniques.
187
+ test_files:
188
+ - spec/microhomology_helper.rb
189
+ - spec/spec_helper.rb