specify_cli 0.0.5
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 +7 -0
- data/.gitignore +4 -0
- data/.rspec +1 -0
- data/Gemfile +17 -0
- data/Gemfile.lock +117 -0
- data/LICENSE.txt +21 -0
- data/README.rdoc +43 -0
- data/Rakefile +15 -0
- data/bin/specify_cli +248 -0
- data/lib/specify.rb +45 -0
- data/lib/specify/branch_parser.rb +85 -0
- data/lib/specify/cli.rb +11 -0
- data/lib/specify/cli/database_setup.rb +46 -0
- data/lib/specify/cli/stubs.rb +63 -0
- data/lib/specify/cli/viewset.rb +21 -0
- data/lib/specify/configuration.rb +12 -0
- data/lib/specify/configuration/config.rb +120 -0
- data/lib/specify/configuration/db_config.rb +162 -0
- data/lib/specify/configuration/host_config.rb +37 -0
- data/lib/specify/database.rb +140 -0
- data/lib/specify/models.rb +43 -0
- data/lib/specify/models/accession.rb +33 -0
- data/lib/specify/models/agent.rb +138 -0
- data/lib/specify/models/app_resource_data.rb +32 -0
- data/lib/specify/models/app_resource_dir.rb +43 -0
- data/lib/specify/models/auto_numbering_scheme.rb +94 -0
- data/lib/specify/models/collecting_event.rb +38 -0
- data/lib/specify/models/collection.rb +67 -0
- data/lib/specify/models/collection_object.rb +127 -0
- data/lib/specify/models/createable.rb +21 -0
- data/lib/specify/models/determination.rb +63 -0
- data/lib/specify/models/discipline.rb +61 -0
- data/lib/specify/models/division.rb +26 -0
- data/lib/specify/models/geography.rb +5 -0
- data/lib/specify/models/geography/administrative_division.rb +32 -0
- data/lib/specify/models/geography/geographic_name.rb +66 -0
- data/lib/specify/models/geography/geography.rb +23 -0
- data/lib/specify/models/institution.rb +13 -0
- data/lib/specify/models/locality.rb +50 -0
- data/lib/specify/models/preparation.rb +53 -0
- data/lib/specify/models/preparation_type.rb +30 -0
- data/lib/specify/models/record_set.rb +55 -0
- data/lib/specify/models/record_set_item.rb +29 -0
- data/lib/specify/models/taxonomy.rb +6 -0
- data/lib/specify/models/taxonomy/common_name.rb +14 -0
- data/lib/specify/models/taxonomy/rank.rb +31 -0
- data/lib/specify/models/taxonomy/taxon.rb +54 -0
- data/lib/specify/models/taxonomy/taxonomy.rb +21 -0
- data/lib/specify/models/tree_queryable.rb +55 -0
- data/lib/specify/models/updateable.rb +20 -0
- data/lib/specify/models/user.rb +104 -0
- data/lib/specify/models/view_set_object.rb +32 -0
- data/lib/specify/number_format.rb +60 -0
- data/lib/specify/services.rb +18 -0
- data/lib/specify/services/service.rb +51 -0
- data/lib/specify/services/stub_generator.rb +291 -0
- data/lib/specify/services/view_loader.rb +177 -0
- data/lib/specify/session.rb +77 -0
- data/lib/specify/user_type.rb +61 -0
- data/lib/specify/version.rb +19 -0
- data/man/specify_cli-database.1 +60 -0
- data/man/specify_cli-database.1.html +137 -0
- data/man/specify_cli-database.1.ronn +53 -0
- data/man/specify_cli-repository.1 +55 -0
- data/man/specify_cli-repository.1.html +128 -0
- data/man/specify_cli-repository.1.ronn +42 -0
- data/man/specify_cli-stubs.1 +177 -0
- data/man/specify_cli-stubs.1.html +239 -0
- data/man/specify_cli-stubs.1.ronn +147 -0
- data/man/specify_cli-viewset.1 +92 -0
- data/man/specify_cli-viewset.1.html +154 -0
- data/man/specify_cli-viewset.1.ronn +72 -0
- data/man/specify_cli.1 +213 -0
- data/man/specify_cli.1.html +252 -0
- data/man/specify_cli.1.ronn +157 -0
- data/spec/branch_parser_spec.rb +94 -0
- data/spec/cli/stubs_spec.rb +44 -0
- data/spec/configuration/config_spec.rb +269 -0
- data/spec/configuration/db_config_spec.rb +299 -0
- data/spec/configuration/host_config_spec.rb +64 -0
- data/spec/database_spec.rb +83 -0
- data/spec/examples.txt +217 -0
- data/spec/helpers.rb +15 -0
- data/spec/models/app_resource_data_spec.rb +38 -0
- data/spec/models/app_resource_dir_spec.rb +8 -0
- data/spec/models/auto_numbering_scheme_spec.rb +78 -0
- data/spec/models/collection_object_spec.rb +92 -0
- data/spec/models/collection_spec.rb +32 -0
- data/spec/models/discipline_spec.rb +31 -0
- data/spec/models/record_set_spec.rb +18 -0
- data/spec/models/user_spec.rb +182 -0
- data/spec/models/view_set_object_spec.rb +70 -0
- data/spec/number_format_spec.rb +43 -0
- data/spec/services/stub_generator_spec.rb +635 -0
- data/spec/services/view_loader_spec.rb +436 -0
- data/spec/session_spec.rb +105 -0
- data/spec/spec_helper.rb +116 -0
- data/spec/support/db.yml +12 -0
- data/spec/support/stub.yaml +17 -0
- data/spec/support/stub_locality.yaml +19 -0
- data/spec/support/viewsets/paleo.views.xml +30 -0
- data/spec/support/viewsets/paleo.xml +30 -0
- data/spec/user_type_spec.rb +79 -0
- data/specify_cli.gemspec +27 -0
- data/specify_cli.rdoc +1 -0
- metadata +246 -0
data/spec/spec_helper.rb
ADDED
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require 'pry'
|
|
4
|
+
|
|
5
|
+
require_relative 'helpers'
|
|
6
|
+
require_relative '../lib/specify'
|
|
7
|
+
|
|
8
|
+
SPSPEC = Specify::Database.new('SPSPEC',
|
|
9
|
+
user: 'specmaster',
|
|
10
|
+
password: 'masterpass')
|
|
11
|
+
DB = SPSPEC.connect
|
|
12
|
+
|
|
13
|
+
# This file was generated by the `rspec --init` command. Conventionally, all
|
|
14
|
+
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
|
|
15
|
+
# The generated `.rspec` file contains `--require spec_helper` which will cause
|
|
16
|
+
# this file to always be loaded, without a need to explicitly require it in any
|
|
17
|
+
# files.
|
|
18
|
+
#
|
|
19
|
+
# Given that it is always loaded, you are encouraged to keep this file as
|
|
20
|
+
# light-weight as possible. Requiring heavyweight dependencies from this file
|
|
21
|
+
# will add to the boot time of your test suite on EVERY test run, even for an
|
|
22
|
+
# individual file that may not need all of that loaded. Instead, consider making
|
|
23
|
+
# a separate helper file that requires the additional dependencies and performs
|
|
24
|
+
# the additional setup, and require it from the spec files that actually need
|
|
25
|
+
# it.
|
|
26
|
+
#
|
|
27
|
+
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
|
|
28
|
+
RSpec.configure do |config|
|
|
29
|
+
# rspec-expectations config goes here. You can use an alternate
|
|
30
|
+
# assertion/expectation library such as wrong or the stdlib/minitest
|
|
31
|
+
# assertions if you prefer.
|
|
32
|
+
config.expect_with :rspec do |expectations|
|
|
33
|
+
# This option will default to `true` in RSpec 4. It makes the `description`
|
|
34
|
+
# and `failure_message` of custom matchers include text for helper methods
|
|
35
|
+
# defined using `chain`, e.g.:
|
|
36
|
+
# be_bigger_than(2).and_smaller_than(4).description
|
|
37
|
+
# # => "be bigger than 2 and smaller than 4"
|
|
38
|
+
# ...rather than:
|
|
39
|
+
# # => "be bigger than 2"
|
|
40
|
+
expectations.include_chain_clauses_in_custom_matcher_descriptions = true
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
# rspec-mocks config goes here. You can use an alternate test double
|
|
44
|
+
# library (such as bogus or mocha) by changing the `mock_with` option here.
|
|
45
|
+
config.mock_with :rspec do |mocks|
|
|
46
|
+
# Prevents you from mocking or stubbing a method that does not exist on
|
|
47
|
+
# a real object. This is generally recommended, and will default to
|
|
48
|
+
# `true` in RSpec 4.
|
|
49
|
+
mocks.verify_partial_doubles = true
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
# This option will default to `:apply_to_host_groups` in RSpec 4 (and will
|
|
53
|
+
# have no way to turn it off -- the option exists only for backwards
|
|
54
|
+
# compatibility in RSpec 3). It causes shared context metadata to be
|
|
55
|
+
# inherited by the metadata hash of host groups and examples, rather than
|
|
56
|
+
# triggering implicit auto-inclusion in groups with matching metadata.
|
|
57
|
+
config.shared_context_metadata_behavior = :apply_to_host_groups
|
|
58
|
+
|
|
59
|
+
# This allows you to limit a spec run to individual examples or groups
|
|
60
|
+
# you care about by tagging them with `:focus` metadata. When nothing
|
|
61
|
+
# is tagged with `:focus`, all examples get run. RSpec also provides
|
|
62
|
+
# aliases for `it`, `describe`, and `context` that include `:focus`
|
|
63
|
+
# metadata: `fit`, `fdescribe` and `fcontext`, respectively.
|
|
64
|
+
config.filter_run_when_matching :focus
|
|
65
|
+
|
|
66
|
+
# Allows RSpec to persist some state between runs in order to support
|
|
67
|
+
# the `--only-failures` and `--next-failure` CLI options. We recommend
|
|
68
|
+
# you configure your source control system to ignore this file.
|
|
69
|
+
config.example_status_persistence_file_path = "spec/examples.txt"
|
|
70
|
+
|
|
71
|
+
# Limits the available syntax to the non-monkey patched syntax that is
|
|
72
|
+
# recommended. For more details, see:
|
|
73
|
+
# - http://rspec.info/blog/2012/06/rspecs-new-expectation-syntax/
|
|
74
|
+
# - http://www.teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
|
|
75
|
+
# - http://rspec.info/blog/2014/05/notable-changes-in-rspec-3/#zero-monkey-patching-mode
|
|
76
|
+
config.disable_monkey_patching!
|
|
77
|
+
|
|
78
|
+
# This setting enables warnings. It's recommended, but in some cases may
|
|
79
|
+
# be too noisy due to issues in dependencies.
|
|
80
|
+
config.warnings = true
|
|
81
|
+
|
|
82
|
+
# Many RSpec users commonly either run the entire suite or an individual
|
|
83
|
+
# file, and it's useful to allow more verbose output when running an
|
|
84
|
+
# individual spec file.
|
|
85
|
+
if config.files_to_run.one?
|
|
86
|
+
# Use the documentation formatter for detailed output,
|
|
87
|
+
# unless a formatter has already been configured
|
|
88
|
+
# (e.g. via a command-line flag).
|
|
89
|
+
config.default_formatter = "doc"
|
|
90
|
+
end
|
|
91
|
+
|
|
92
|
+
# Print the 10 slowest examples and example groups at the
|
|
93
|
+
# end of the spec run, to help surface which specs are running
|
|
94
|
+
# particularly slow.
|
|
95
|
+
config.profile_examples = 10
|
|
96
|
+
|
|
97
|
+
# Run specs in random order to surface order dependencies. If you find an
|
|
98
|
+
# order dependency and want to debug it, you can fix the order by providing
|
|
99
|
+
# the seed, which is printed after each run.
|
|
100
|
+
# --seed 1234
|
|
101
|
+
config.order = :random
|
|
102
|
+
|
|
103
|
+
# Seed global randomization in this process using the `--seed` CLI option.
|
|
104
|
+
# Setting this allows you to use `--seed` to deterministically reproduce
|
|
105
|
+
# test failures related to randomization by passing the same `--seed` value
|
|
106
|
+
# as the one that triggered the failure.
|
|
107
|
+
Kernel.srand config.seed
|
|
108
|
+
|
|
109
|
+
config.include Helpers
|
|
110
|
+
|
|
111
|
+
config.warnings = false
|
|
112
|
+
|
|
113
|
+
config.around do |example|
|
|
114
|
+
DB.transaction(rollback: :always, auto_savepoint: true) { example.run }
|
|
115
|
+
end
|
|
116
|
+
end
|
data/spec/support/db.yml
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
---
|
|
2
|
+
:stub_generator:
|
|
3
|
+
:host: localhost
|
|
4
|
+
:database: SPSPEC
|
|
5
|
+
:collection: Test Collection
|
|
6
|
+
:config: spec/support/db.yml
|
|
7
|
+
dataset_name: 'stubs with default locality'
|
|
8
|
+
accession: 2018-AA-001
|
|
9
|
+
cataloger: specmanager
|
|
10
|
+
collecting_data:
|
|
11
|
+
Country: United States
|
|
12
|
+
default_locality_name: default stub locality US
|
|
13
|
+
determination:
|
|
14
|
+
Family: Asaphidae
|
|
15
|
+
preparation:
|
|
16
|
+
:type: Specimen
|
|
17
|
+
:count: 1
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
---
|
|
2
|
+
:stub_generator:
|
|
3
|
+
:host: localhost
|
|
4
|
+
:database: SPSPEC
|
|
5
|
+
:collection: Test Collection
|
|
6
|
+
:config: spec/support/db.yml
|
|
7
|
+
dataset_name: 'stubs with locality'
|
|
8
|
+
accession: 2018-AA-001
|
|
9
|
+
cataloger: specmanager
|
|
10
|
+
collecting_data:
|
|
11
|
+
Country: United States
|
|
12
|
+
State: Kansas
|
|
13
|
+
County: Douglas County
|
|
14
|
+
:locality: Downtown Lawrence
|
|
15
|
+
determination:
|
|
16
|
+
Family: Asaphidae
|
|
17
|
+
preparation:
|
|
18
|
+
:type: Specimen
|
|
19
|
+
:count: 1
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<viewset name="Paleo Views" i18nresname="views" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
|
3
|
+
<!-- dude, it would be so awesome if that worked!! -->
|
|
4
|
+
<views>
|
|
5
|
+
<view name="CollectionObject" class="edu.ku.brc.specify.datamodel.CollectionObject" busrules="edu.ku.brc.specify.datamodel.busrules.CollectionObjectBusRules" isinternal="false" resourcelabels="false">
|
|
6
|
+
<desc><![CDATA[The Collection Object form.]]></desc>
|
|
7
|
+
<altviews>
|
|
8
|
+
<altview name="Collection Object View" viewdef="Collection Object" mode="view"/>
|
|
9
|
+
<altview name="Collection Object Edit" viewdef="Collection Object" mode="edit" default="true"/>
|
|
10
|
+
</altviews>
|
|
11
|
+
</view>
|
|
12
|
+
</views>
|
|
13
|
+
|
|
14
|
+
<viewdefs>
|
|
15
|
+
<viewdef type="form" name="Collection Object" class="edu.ku.brc.specify.datamodel.CollectionObject" gettable="edu.ku.brc.af.ui.forms.DataGetterForObj" settable="edu.ku.brc.af.ui.forms.DataSetterForObj">
|
|
16
|
+
<desc><![CDATA[The Collection Object form.]]></desc>
|
|
17
|
+
<enableRules/>
|
|
18
|
+
<columnDef>100px,2px,195px,5px,96px,2px,210px,5px,94px,2px,116px,15px,p:g</columnDef>
|
|
19
|
+
<columnDef os="lnx">115px,2px,195px,5px,125px,2px,210px,5px,125px,2px,131px,15px,p:g</columnDef>
|
|
20
|
+
<columnDef os="mac">130px,2px,215px,5px,128px,2px,260px,5px,138px,2px,145px,15px,p:g</columnDef>
|
|
21
|
+
<columnDef os="exp">p,2px,min(p;250px),5px:g,p,2px,p:g,5px:g,p,2px,p:g(2),p,p:g</columnDef>
|
|
22
|
+
<rowDef auto="true" cell="p" sep="2px"/>
|
|
23
|
+
<rows>
|
|
24
|
+
<row>
|
|
25
|
+
<cell type="label" label="Viewset for Collection, uploaded from sp_view_loader" colspan="13" initialize="align=center"/>
|
|
26
|
+
</row>
|
|
27
|
+
</rows>
|
|
28
|
+
</viewdef>
|
|
29
|
+
</viewdefs>
|
|
30
|
+
</viewset>
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<viewset name="Paleo Views" i18nresname="views" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
|
3
|
+
<!-- dude, it would be so awesome if that worked!! -->
|
|
4
|
+
<views>
|
|
5
|
+
<view name="CollectionObject" class="edu.ku.brc.specify.datamodel.CollectionObject" busrules="edu.ku.brc.specify.datamodel.busrules.CollectionObjectBusRules" isinternal="false" resourcelabels="false">
|
|
6
|
+
<desc><![CDATA[The Collection Object form.]]></desc>
|
|
7
|
+
<altviews>
|
|
8
|
+
<altview name="Collection Object View" viewdef="Collection Object" mode="view"/>
|
|
9
|
+
<altview name="Collection Object Edit" viewdef="Collection Object" mode="edit" default="true"/>
|
|
10
|
+
</altviews>
|
|
11
|
+
</view>
|
|
12
|
+
</views>
|
|
13
|
+
|
|
14
|
+
<viewdefs>
|
|
15
|
+
<viewdef type="form" name="Collection Object" class="edu.ku.brc.specify.datamodel.CollectionObject" gettable="edu.ku.brc.af.ui.forms.DataGetterForObj" settable="edu.ku.brc.af.ui.forms.DataSetterForObj">
|
|
16
|
+
<desc><![CDATA[The Collection Object form.]]></desc>
|
|
17
|
+
<enableRules/>
|
|
18
|
+
<columnDef>100px,2px,195px,5px,96px,2px,210px,5px,94px,2px,116px,15px,p:g</columnDef>
|
|
19
|
+
<columnDef os="lnx">115px,2px,195px,5px,125px,2px,210px,5px,125px,2px,131px,15px,p:g</columnDef>
|
|
20
|
+
<columnDef os="mac">130px,2px,215px,5px,128px,2px,260px,5px,138px,2px,145px,15px,p:g</columnDef>
|
|
21
|
+
<columnDef os="exp">p,2px,min(p;250px),5px:g,p,2px,p:g,5px:g,p,2px,p:g(2),p,p:g</columnDef>
|
|
22
|
+
<rowDef auto="true" cell="p" sep="2px"/>
|
|
23
|
+
<rows>
|
|
24
|
+
<row>
|
|
25
|
+
<cell type="label" label="Viewset for Collection, uploaded from sp_view_loader" colspan="13" initialize="align=center"/>
|
|
26
|
+
</row>
|
|
27
|
+
</rows>
|
|
28
|
+
</viewdef>
|
|
29
|
+
</viewdefs>
|
|
30
|
+
</viewset>
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Tests for the
|
|
4
|
+
module Specify
|
|
5
|
+
RSpec.describe UserType do
|
|
6
|
+
let :collection do
|
|
7
|
+
Model::Collection.first CollectionName: 'Test Collection'
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
let(:user_type) { described_class.new('guest') }
|
|
11
|
+
|
|
12
|
+
it { expect(user_type).to respond_to :save }
|
|
13
|
+
|
|
14
|
+
it { expect(user_type).to respond_to :view_set_dir= }
|
|
15
|
+
|
|
16
|
+
describe '#add_app_resource_dir(values)' do
|
|
17
|
+
let(:agent) { Model::Agent.first Email: 'john.doe@example.com' }
|
|
18
|
+
let :values do
|
|
19
|
+
{
|
|
20
|
+
DisciplineType: 'spec type',
|
|
21
|
+
UserType: user_type.name,
|
|
22
|
+
IsPersonal: false,
|
|
23
|
+
collection: collection,
|
|
24
|
+
discipline: collection.discipline,
|
|
25
|
+
}
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
subject do
|
|
29
|
+
user_type.add_app_resource_dir(values.merge(created_by: agent,
|
|
30
|
+
user: agent.user))
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
it do
|
|
34
|
+
is_expected.to be_a(Model::AppResourceDir)
|
|
35
|
+
.and have_attributes DisciplineType: 'spec type',
|
|
36
|
+
UserType: 'guest',
|
|
37
|
+
IsPersonal: false,
|
|
38
|
+
collection: collection,
|
|
39
|
+
discipline: collection.discipline
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
describe '#valid?' do
|
|
44
|
+
context 'when the user type name is valid' do
|
|
45
|
+
subject { user_type.valid? }
|
|
46
|
+
|
|
47
|
+
it { is_expected.to be_truthy }
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
context 'when the user type name is invalid' do
|
|
51
|
+
subject { described_class.new('root').valid? }
|
|
52
|
+
|
|
53
|
+
it { is_expected.to be_falsey }
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
describe '#view_set_dir(collection)' do
|
|
58
|
+
subject { user_type.view_set_dir(collection) }
|
|
59
|
+
|
|
60
|
+
it do
|
|
61
|
+
is_expected
|
|
62
|
+
.to have_attributes DisciplineType: 'Invertebrate Paleontology',
|
|
63
|
+
IsPersonal: false,
|
|
64
|
+
UserType: 'guest',
|
|
65
|
+
collection: collection,
|
|
66
|
+
discipline: collection.discipline
|
|
67
|
+
end
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
describe '#view_set(collection)' do
|
|
71
|
+
subject { user_type.view_set(collection) }
|
|
72
|
+
|
|
73
|
+
it 'returns the ViewSetObject for the given collection' do
|
|
74
|
+
is_expected
|
|
75
|
+
.to have_attributes Name: 'Paleo Views'
|
|
76
|
+
end
|
|
77
|
+
end
|
|
78
|
+
end
|
|
79
|
+
end
|
data/specify_cli.gemspec
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
require File.join([File.dirname(__FILE__),'lib','specify','version.rb'])
|
|
2
|
+
|
|
3
|
+
spec = Gem::Specification.new do |s|
|
|
4
|
+
s.name = 'specify_cli'
|
|
5
|
+
s.version = Specify::VERSION
|
|
6
|
+
s.author = 'Martin Stein'
|
|
7
|
+
s.licenses = ['MIT']
|
|
8
|
+
s.email = 'loveablelobster@fastmail.fm'
|
|
9
|
+
s.homepage = 'https://github.com/loveablelobster/specify_cli'
|
|
10
|
+
s.platform = Gem::Platform::RUBY
|
|
11
|
+
s.summary = Specify::SUMMARY
|
|
12
|
+
s.description = Specify::DESCRIPTION
|
|
13
|
+
s.files = `git ls-files`.split("
|
|
14
|
+
")
|
|
15
|
+
s.require_paths << 'lib'
|
|
16
|
+
s.has_rdoc = true
|
|
17
|
+
s.extra_rdoc_files = ['README.rdoc','specify_cli.rdoc']
|
|
18
|
+
s.rdoc_options << '--title' << 'specify_cli' << '--main' << 'README.rdoc' << '-ri'
|
|
19
|
+
s.bindir = 'bin'
|
|
20
|
+
s.executables << 'specify_cli'
|
|
21
|
+
s.add_development_dependency('rake')
|
|
22
|
+
s.add_development_dependency('rdoc')
|
|
23
|
+
s.add_development_dependency('aruba')
|
|
24
|
+
s.add_runtime_dependency('gli','2.17.2')
|
|
25
|
+
s.add_runtime_dependency('mysql2','0.5.2')
|
|
26
|
+
s.add_runtime_dependency('sequel','5.11.0')
|
|
27
|
+
end
|
data/specify_cli.rdoc
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
= specify_cli - A command line interface for _Specify_
|
metadata
ADDED
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: specify_cli
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 0.0.5
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Martin Stein
|
|
8
|
+
autorequire:
|
|
9
|
+
bindir: bin
|
|
10
|
+
cert_chain: []
|
|
11
|
+
date: 2018-08-30 00:00:00.000000000 Z
|
|
12
|
+
dependencies:
|
|
13
|
+
- !ruby/object:Gem::Dependency
|
|
14
|
+
name: rake
|
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
|
16
|
+
requirements:
|
|
17
|
+
- - ">="
|
|
18
|
+
- !ruby/object:Gem::Version
|
|
19
|
+
version: '0'
|
|
20
|
+
type: :development
|
|
21
|
+
prerelease: false
|
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
23
|
+
requirements:
|
|
24
|
+
- - ">="
|
|
25
|
+
- !ruby/object:Gem::Version
|
|
26
|
+
version: '0'
|
|
27
|
+
- !ruby/object:Gem::Dependency
|
|
28
|
+
name: rdoc
|
|
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: aruba
|
|
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: gli
|
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
|
58
|
+
requirements:
|
|
59
|
+
- - '='
|
|
60
|
+
- !ruby/object:Gem::Version
|
|
61
|
+
version: 2.17.2
|
|
62
|
+
type: :runtime
|
|
63
|
+
prerelease: false
|
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
65
|
+
requirements:
|
|
66
|
+
- - '='
|
|
67
|
+
- !ruby/object:Gem::Version
|
|
68
|
+
version: 2.17.2
|
|
69
|
+
- !ruby/object:Gem::Dependency
|
|
70
|
+
name: mysql2
|
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
|
72
|
+
requirements:
|
|
73
|
+
- - '='
|
|
74
|
+
- !ruby/object:Gem::Version
|
|
75
|
+
version: 0.5.2
|
|
76
|
+
type: :runtime
|
|
77
|
+
prerelease: false
|
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
79
|
+
requirements:
|
|
80
|
+
- - '='
|
|
81
|
+
- !ruby/object:Gem::Version
|
|
82
|
+
version: 0.5.2
|
|
83
|
+
- !ruby/object:Gem::Dependency
|
|
84
|
+
name: sequel
|
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
|
86
|
+
requirements:
|
|
87
|
+
- - '='
|
|
88
|
+
- !ruby/object:Gem::Version
|
|
89
|
+
version: 5.11.0
|
|
90
|
+
type: :runtime
|
|
91
|
+
prerelease: false
|
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
93
|
+
requirements:
|
|
94
|
+
- - '='
|
|
95
|
+
- !ruby/object:Gem::Version
|
|
96
|
+
version: 5.11.0
|
|
97
|
+
description: |
|
|
98
|
+
specify_cli is a tool that allows certain tasks in a Specify database
|
|
99
|
+
(http://www.sustain.specifysoftware.org) to be carried out from the command
|
|
100
|
+
line.
|
|
101
|
+
Currently supported tasks:
|
|
102
|
+
- upload of views to the database
|
|
103
|
+
- generation of stub records
|
|
104
|
+
email: loveablelobster@fastmail.fm
|
|
105
|
+
executables:
|
|
106
|
+
- specify_cli
|
|
107
|
+
extensions: []
|
|
108
|
+
extra_rdoc_files:
|
|
109
|
+
- README.rdoc
|
|
110
|
+
- specify_cli.rdoc
|
|
111
|
+
files:
|
|
112
|
+
- ".gitignore"
|
|
113
|
+
- ".rspec"
|
|
114
|
+
- Gemfile
|
|
115
|
+
- Gemfile.lock
|
|
116
|
+
- LICENSE.txt
|
|
117
|
+
- README.rdoc
|
|
118
|
+
- Rakefile
|
|
119
|
+
- bin/specify_cli
|
|
120
|
+
- lib/specify.rb
|
|
121
|
+
- lib/specify/branch_parser.rb
|
|
122
|
+
- lib/specify/cli.rb
|
|
123
|
+
- lib/specify/cli/database_setup.rb
|
|
124
|
+
- lib/specify/cli/stubs.rb
|
|
125
|
+
- lib/specify/cli/viewset.rb
|
|
126
|
+
- lib/specify/configuration.rb
|
|
127
|
+
- lib/specify/configuration/config.rb
|
|
128
|
+
- lib/specify/configuration/db_config.rb
|
|
129
|
+
- lib/specify/configuration/host_config.rb
|
|
130
|
+
- lib/specify/database.rb
|
|
131
|
+
- lib/specify/models.rb
|
|
132
|
+
- lib/specify/models/accession.rb
|
|
133
|
+
- lib/specify/models/agent.rb
|
|
134
|
+
- lib/specify/models/app_resource_data.rb
|
|
135
|
+
- lib/specify/models/app_resource_dir.rb
|
|
136
|
+
- lib/specify/models/auto_numbering_scheme.rb
|
|
137
|
+
- lib/specify/models/collecting_event.rb
|
|
138
|
+
- lib/specify/models/collection.rb
|
|
139
|
+
- lib/specify/models/collection_object.rb
|
|
140
|
+
- lib/specify/models/createable.rb
|
|
141
|
+
- lib/specify/models/determination.rb
|
|
142
|
+
- lib/specify/models/discipline.rb
|
|
143
|
+
- lib/specify/models/division.rb
|
|
144
|
+
- lib/specify/models/geography.rb
|
|
145
|
+
- lib/specify/models/geography/administrative_division.rb
|
|
146
|
+
- lib/specify/models/geography/geographic_name.rb
|
|
147
|
+
- lib/specify/models/geography/geography.rb
|
|
148
|
+
- lib/specify/models/institution.rb
|
|
149
|
+
- lib/specify/models/locality.rb
|
|
150
|
+
- lib/specify/models/preparation.rb
|
|
151
|
+
- lib/specify/models/preparation_type.rb
|
|
152
|
+
- lib/specify/models/record_set.rb
|
|
153
|
+
- lib/specify/models/record_set_item.rb
|
|
154
|
+
- lib/specify/models/taxonomy.rb
|
|
155
|
+
- lib/specify/models/taxonomy/common_name.rb
|
|
156
|
+
- lib/specify/models/taxonomy/rank.rb
|
|
157
|
+
- lib/specify/models/taxonomy/taxon.rb
|
|
158
|
+
- lib/specify/models/taxonomy/taxonomy.rb
|
|
159
|
+
- lib/specify/models/tree_queryable.rb
|
|
160
|
+
- lib/specify/models/updateable.rb
|
|
161
|
+
- lib/specify/models/user.rb
|
|
162
|
+
- lib/specify/models/view_set_object.rb
|
|
163
|
+
- lib/specify/number_format.rb
|
|
164
|
+
- lib/specify/services.rb
|
|
165
|
+
- lib/specify/services/service.rb
|
|
166
|
+
- lib/specify/services/stub_generator.rb
|
|
167
|
+
- lib/specify/services/view_loader.rb
|
|
168
|
+
- lib/specify/session.rb
|
|
169
|
+
- lib/specify/user_type.rb
|
|
170
|
+
- lib/specify/version.rb
|
|
171
|
+
- man/specify_cli-database.1
|
|
172
|
+
- man/specify_cli-database.1.html
|
|
173
|
+
- man/specify_cli-database.1.ronn
|
|
174
|
+
- man/specify_cli-repository.1
|
|
175
|
+
- man/specify_cli-repository.1.html
|
|
176
|
+
- man/specify_cli-repository.1.ronn
|
|
177
|
+
- man/specify_cli-stubs.1
|
|
178
|
+
- man/specify_cli-stubs.1.html
|
|
179
|
+
- man/specify_cli-stubs.1.ronn
|
|
180
|
+
- man/specify_cli-viewset.1
|
|
181
|
+
- man/specify_cli-viewset.1.html
|
|
182
|
+
- man/specify_cli-viewset.1.ronn
|
|
183
|
+
- man/specify_cli.1
|
|
184
|
+
- man/specify_cli.1.html
|
|
185
|
+
- man/specify_cli.1.ronn
|
|
186
|
+
- spec/branch_parser_spec.rb
|
|
187
|
+
- spec/cli/stubs_spec.rb
|
|
188
|
+
- spec/configuration/config_spec.rb
|
|
189
|
+
- spec/configuration/db_config_spec.rb
|
|
190
|
+
- spec/configuration/host_config_spec.rb
|
|
191
|
+
- spec/database_spec.rb
|
|
192
|
+
- spec/examples.txt
|
|
193
|
+
- spec/helpers.rb
|
|
194
|
+
- spec/models/app_resource_data_spec.rb
|
|
195
|
+
- spec/models/app_resource_dir_spec.rb
|
|
196
|
+
- spec/models/auto_numbering_scheme_spec.rb
|
|
197
|
+
- spec/models/collection_object_spec.rb
|
|
198
|
+
- spec/models/collection_spec.rb
|
|
199
|
+
- spec/models/discipline_spec.rb
|
|
200
|
+
- spec/models/record_set_spec.rb
|
|
201
|
+
- spec/models/user_spec.rb
|
|
202
|
+
- spec/models/view_set_object_spec.rb
|
|
203
|
+
- spec/number_format_spec.rb
|
|
204
|
+
- spec/services/stub_generator_spec.rb
|
|
205
|
+
- spec/services/view_loader_spec.rb
|
|
206
|
+
- spec/session_spec.rb
|
|
207
|
+
- spec/spec_helper.rb
|
|
208
|
+
- spec/support/db.yml
|
|
209
|
+
- spec/support/stub.yaml
|
|
210
|
+
- spec/support/stub_locality.yaml
|
|
211
|
+
- spec/support/viewsets/paleo.views.xml
|
|
212
|
+
- spec/support/viewsets/paleo.xml
|
|
213
|
+
- spec/user_type_spec.rb
|
|
214
|
+
- specify_cli.gemspec
|
|
215
|
+
- specify_cli.rdoc
|
|
216
|
+
homepage: https://github.com/loveablelobster/specify_cli
|
|
217
|
+
licenses:
|
|
218
|
+
- MIT
|
|
219
|
+
metadata: {}
|
|
220
|
+
post_install_message:
|
|
221
|
+
rdoc_options:
|
|
222
|
+
- "--title"
|
|
223
|
+
- specify_cli
|
|
224
|
+
- "--main"
|
|
225
|
+
- README.rdoc
|
|
226
|
+
- "-ri"
|
|
227
|
+
require_paths:
|
|
228
|
+
- lib
|
|
229
|
+
- lib
|
|
230
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
231
|
+
requirements:
|
|
232
|
+
- - ">="
|
|
233
|
+
- !ruby/object:Gem::Version
|
|
234
|
+
version: '0'
|
|
235
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
236
|
+
requirements:
|
|
237
|
+
- - ">="
|
|
238
|
+
- !ruby/object:Gem::Version
|
|
239
|
+
version: '0'
|
|
240
|
+
requirements: []
|
|
241
|
+
rubyforge_project:
|
|
242
|
+
rubygems_version: 2.7.6
|
|
243
|
+
signing_key:
|
|
244
|
+
specification_version: 4
|
|
245
|
+
summary: A command line interface for Specify
|
|
246
|
+
test_files: []
|